Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Concatenate

Status
Not open for further replies.

amerifax

Technical User
Dec 28, 2006
37
I am not sure if I am posting this in the correct spot...if not I apologize.

I am using Access 2007. I have three columns, fst,lst and name. How do I get the column "name" to contain "fst and last"? So basically I have a table with first name and last name in seperate fields. I would like to concatenate them into one field called name. What is the simplest way to do this?

Thanks in advance for any help.

Bob
 
What is the simplest way to do this
Don't store calculated/derived values in a table but use a query, e.g.:
SELECT fst & ' ' & lst AS name FROM yourTable

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Wow that was quite simple, thanks soooo much!
I do have one more part to it if possible. Some of the LastName (GrantorLastName) fields contain Company information and therefore have nothing in the FirstName field. Is there an easy enough way not add the space if FirstName does not contain anything.

Thanks so much again for your help.

Bob
 
SELECT Trim(fst & ' ' & lst) AS name FROM yourTable

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Well that was even easier than your first help. Thank you very much. I really appreciate your help. Access is pretty new to me but with people like you helping me out I am finding my way around really easily!

Thanks again!

Bob
 
Bob,
When someone helps you with the correct answer, you should click the link to "Thank XXX for this valuable post!"

This credits a good reply and marks the thread as having been answered.

Duane
Hook'D on Access
MS Access MVP
 
Thanks dhookom soory about the over site. I agree credit due but was not aware about the button. I run a IPBoard and didn't have a clue.

Bob
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top