hundreds of IDs in one table

Lucy02

Registered User.
Local time
Yesterday, 23:52
Joined
Nov 25, 2005
Messages
36
Hi Guys

I'm sure someone has asked this before but I have been searching for ages and cannot find an answer. I have a table which i enter all appointments that have been made to which companies. So that i don't have to enter the company name in full each time they get an appointment I thought it would be easier to give each company an ID which I type in instead of the full name. However there are hundreds of companies and it is vertually impossible to remember the ID's for each individual company. Is there anyway of creating a drop down list where i choose the company name and id enters automatically in for me or something along these lines?

Thanks in advance
 
Hi Sorry I can't open the file!
 
Just use a combobox, set it to 2 columns, column width of 0;2 and then create a query with the following SQL, based on the structure I gave you in anothe post.

SELECT CompanyID, CompanyName
FROM tblCompanies
ORDER BY CompanyName;

Save the query as qryCompanies and set this query as the combo's RowSource.
 
Hi Sorry that's completely lost me! Do i need to put a company name field in my contacts table now to go alongside the company id or not?
 
No, you don't. You have the CompanyID in the Contacts table. That's enough.

I don't see why you would need the Contacts table with this problem.
 
I want to create a form so that all of the contacts made can be entered. But because there are hundreds of companies I can't remember what each individual id is for each company so when i fill inthe contacts form i want to be able to select the company which was contacted and have their id number enter automatically?
 
You only need the combo I described on the form. Although it will look like you are selecting a company it is putting the ID into the table, which is all you need.
 

Users who are viewing this thread

Back
Top Bottom