First and Last name in Form - what is the best way to handle this?

jonathanchye

Registered User.
Local time
Today, 23:30
Joined
Mar 8, 2011
Messages
448
Hi all,

(MS Access 2010)

I have a linked table (tblGlobalAddressList) in my current database which the company's global address list. The fields in tblGlobalAddressList includes First Name, Last Name, Department, ContactNo.

I have created a form in my current DB and I want to pull First and Last names from tblGlobalAddressList. How I currently do it now is to create two combo boxes and link them to First and Last Name fields in tblGlobalAddressList. Reason I do this is because users can first select their last name and then then second combo box will narrow down their first name to further enhance data integrity.

However, I've encountered a problem here. I want to store both the First and Last name as a SINGLE field in the table my form is linked too.

I can't find a way to do this at the moment. Also, is it actually easier to first run a query and then use SQL to combine (Union?) First and Last name and just use a Text box in my form instead of 2 combo boxes?
 
Uncle G's approach is the correct one! When stored in a Table the name should always be stored as two fields, then concatenated when necessary, as his SELECT statement shows. Trust me, it is always easier to concatenate data together than it is to parse it into it's various components!

Linq ;0)>
 
Uncle G's approach is the correct one! When stored in a Table the name should always be stored as two fields, then concatenated when necessary, as his SELECT statement shows. Trust me, it is always easier to concatenate data together than it is to parse it into it's various components!

Linq ;0)>

Truer words were never spoken. [First Name] & " " & [Last Name] is always the better approach.
 
Teach him to fish, and he'll sit on the dock for hours and drink beer."
That's a slight misquote! I believe it should be

"Teach him to fish, and he'll sit on the dock for hours, drink beer, and tell lies!" :D
 
EDIT: Never mind I found the problem :)
EDIT2: Can you clarity a little bit about the "AS" part. Why is the first property "FirstLast"? Does this correspond to the Control Source on the main form I want to save the field in? Or just a new name for the combined fields?

Thanks a lot mate! :)
 
Last edited:

Users who are viewing this thread

Back
Top Bottom