On Wed, 20 Apr 2005 18:03:47 GMT, "Dave Elliott"
<(E-Mail Removed)> wrote:
>Yes, both tables contain the name city
>postal code and zip do not match
>state and region do not match
>Should i use the lookup for both the customers table for the field city
>using the table tblzipcode
>and also a lookup on my customers form to do the same?
I would N E V E R use a Lookup Field in *any* table.
I would frequently use Combo Boxes on forms, to display one value
while storing another.
Some of my collegues aren't quite so vehement, and a few even use
table lookup fields occasionally.
See
http://www.mvps.org/access/lookupfields.htm for a critique.
You're using a relational database. Use it relationally! For a Report
use a Query *JOINING* your customers table to tblZipcode. Display the
city from tblZipcode, display the customer information from Customers.
It is not necessary nor is it beneficial to have a (redundant) City
field in the Customers table (unless you have cases where one zipcode
covers multiple cities, and even there the post office has a
"preferred city").
If you just want to display other fields from the combo box on the
form, set the Control Source property of textboxes to
=cboZipcode.Column(n)
where cboZipcode is the name of the combo box, and (n) is the zero
based index of the desired field in the combo's rowsource query - i.e.
(2) will be the *third* field in that query. This will display the
actual field in that query; if the table contains a lookup field,
you'll see the ID that is actually stored in the table, not the
artificial "lookup".
John W. Vinson[MVP]