Concatenate two fields into a third one [Access 2003]

Fr_Picon Posted messages 4 Status Membre -  
 Tessel75 -
Hello,
I searched the web for a solution to this very simple question and I couldn't figure it out...
I have two fields "location" and "object_number" and I would like them to be concatenated in a third one to get a result like "Paris1" when I move from one record to another. This field must be unique.

In the table, I tried using "default value" but I can't seem to reference the fields.
I created an update query but I can't seem to call it when exiting a new record.

Thanks in advance

Configuration: Windows 7 / Firefox 37.0

2 réponses

Tessel75
 
Hello,
For all concatenations between 2 fields (or cells or other elements in Office), the link is "&". That is: [Field1] & [Field2]
Note: If you want a space between the 2 terms, you need to provide 2 times "&", i.e. [Field1] " "& [Field2]
Best wishes
0
Fr_Picon Posted messages 4 Status Membre
 
Good evening, thank you for the response but it doesn't tell me where to put this concatenation formula. I'm a beginner with Access so your answer isn't very clear!
0
castours Posted messages 2955 Registration date   Status Membre Last intervention   217 > Fr_Picon Posted messages 4 Status Membre
 
Hello
In a query in a new field
For example
you have a first name field and a last name field. You want to combine the two. You create a field FirstName/LastName:[FirstName]&" "[LastName]. If you want a separator between the two, you use &"-"&.
0