473,378 Members | 1,377 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

How to trim a string in a table, text field?

4
Hi all. Please help.

I have a field that is filled automatically from other resource but I want to trim the string to 8 characters from the right, how do I do that?

Sample records, I want my table to show only the 8 characters from the right.
0000000000000000A1008182
0000000000000000A1012642

Thank you in advance.
Jan 27 '16 #1
6 1380
Seth Schrock
2,965 Expert 2GB
The Right() function returns the specified number of characters from right to left. I can't help with implementation without more information.
Jan 27 '16 #2
calaxan
12
Right([TableName]![FieldName],8)
Jan 27 '16 #3
xmanx
4
Thanks Seth.

I am new to MS Access.

I have a table the data is automatically loaded from other resource.

The only useful characters are the 8 ones, 0000000000000000A1008182, from the right.
I need to trim them in order to create queries.

I tried to trim them by using the right() expression in query but the trimmed data wouldn't match to my other table.

Just wondering if I can directly trim the records in the table.

I hope I am not confusing you any further.

Thanks again.
Jan 27 '16 #4
xmanx
4
Thanks Calaxan.

Where should I enter this code?

Sorry, I am new to MS Access.
Jan 27 '16 #5
Seth Schrock
2,965 Expert 2GB
What is in the "other table" you mention? What does it need to match to?
Jan 27 '16 #6
xmanx
4
Actually problem solved, thanks for all your help.
Jan 27 '16 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: Rick Caborn | last post by:
Does anyone know of a way to execute sql code from a dynamically built text field? Before beginning, let me state that I know this db architecture is built solely for frustration and I hope to...
3
by: Ronnie | last post by:
Hi All, A newbie here having a hard time figuring out how to parse out the City, State and Zip from a text field. I have a text field called "Registration" with a size of 40. In this field...
8
by: Lyn | last post by:
Hi, Can anyone tell me how the initial value displayed in Combo Box is determined when a form is opened? I am loading the dropdown from one field ("CategoryName") of a table, with "ORDER BY ". ...
2
by: Tom Jorgenson | last post by:
I have a DropDownList whose items are populated simply via the Items property of the control. The field represents the gender of a client and the items are simply 'Male', 'Female', and 'Choose...
4
by: steph | last post by:
Hello, I've got a text field in an access form (Microsoft Access 2002, SP3), that the user has to fill out. Now I don't want the user to leave this field (and this record) until he has filled...
1
by: Toma Marinov | last post by:
Hello ! I"m trying to insert large string (more than 1000) into TEXT field in SQL Server but it truncate the data to 255 symbols. Is there any other way to insert large string into TEXT field...
22
by: Terry Olsen | last post by:
I have an app that makes decisions based on string content. I need to make sure that a string does not contain only spaces or newlines. I am using the syntax 'Trim(String)" and it works fine. I...
3
by: Alan Carpenter | last post by:
Hi. In Access97 I can set defaults for new Fields in Tools - Options - Tables/Queries. I can set some Form/Report defaults in the Normal Template. Now I need to work with AllowZeroLength =...
7
by: kirkgilbert | last post by:
I am trying to do an onchange event in a form using a text field. The form is tied to a record set that is part of a repeated region. One the first record when I edit the data it works perfectly. ...
2
by: radforms | last post by:
Hi All, just wondering someone out there could help me solve a little problem in my mysql database: Table 1 Name: wp_wpsc_product_files Fields: ID, Name, Description, Additional_Description ...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.