Combination of data from two field

racdata

Registered User.
Local time
Today, 05:21
Joined
Oct 30, 2002
Messages
74
Hi all
I have a table with data like
Field 1 = Ref_No (IM1006/0548)
Field 2 = Loc (CBUS)

I want to combine these two fields in a separate field

Must look like this
Field LocNo = CBUS0548
 
Use something like LocNo: Loc & Right([Ref_No],4) in a query
or =[Loc] & Right([Ref_No],4) in Control Source ;) lightray
 
Yep, above sollution will work provided that the /xxxx is always 4 characters. If not, you'll get faulty results.

Use this code to be absolutely sure:

LocNo: [Field 2] & Mid([Field 1];InStr(1;[Field 1];"/")+1;Len([Field 1])-InStr(1;[Field 1];"/"))
 

Users who are viewing this thread

Back
Top Bottom