I have a form in Access 2007 with a field that the user will enter a ZIP Code. I have a table/query that contains every ZIP Code I need (well over 80,000). The data contains not only the ZIP Codes for each location (with city, county, state) but also for surrounding communities that use the same ZIP Code i.e. the ZIP Code for the main city is 12345 and the surrounding communities do not have their own ZIP Codes but share the one with the main city.
The problem is that the main tables contains addresses that might reference one of these surrounding communities and we would want to maintain that address as entered. If I had a one-to-one relationship it would be easy... but since a single ZIP Code could refer to multiple cities/towns I don't know how to do it. I want the user performing the data entry to be able to enter a ZIP Code. The ZIP Code is then looked up in the ZIP Code table and if it is a one-to-one correspondence than I want it to populate the fields for the city, county, and state (and display them on the form).
If there is a one-to-many correspondence, then I want the user to be able to select from a list of the possible cities and after the selection, the correct city/county/state fields are populated. Is this possible?
The problem is that the main tables contains addresses that might reference one of these surrounding communities and we would want to maintain that address as entered. If I had a one-to-one relationship it would be easy... but since a single ZIP Code could refer to multiple cities/towns I don't know how to do it. I want the user performing the data entry to be able to enter a ZIP Code. The ZIP Code is then looked up in the ZIP Code table and if it is a one-to-one correspondence than I want it to populate the fields for the city, county, and state (and display them on the form).
If there is a one-to-many correspondence, then I want the user to be able to select from a list of the possible cities and after the selection, the correct city/county/state fields are populated. Is this possible?
Comment