M
MrDangerous
The source of my problem I'm having is that several small towns in our area
have the same zip and two cities in my area (Savannah and Charleston) have
several zips, so neither the zip or the city name can be the primary index.
So, I gave them an autonumber primary key instead.
I have a table for work orders, and a table of job site addresses that
include a combo box that references another table named CityTimeMiledge with
the following fields: ID(autonumber), City(text), State(text), Zip(text),
Miledge(text), and Travel Time(text), with City as the bound column.
Everything works fine until I try to build a query using the table. The
query which searches out work orders by specific locations (which has a
combo box with a row source of SELECT[Site Locations].[Site Name], [Site
Locations].Address, [Site Locations].City, [Site Locations].[Phone Number]
FROM [Site Locations]; with [Site Name] as the bound column) will have
multiple entries for every site in Savannah, one for every zip code in
Savannah. If I change the bound column for City to the ID, the site
locations combo box shows the ID number in the address, not the city, and
the queries come up blank.
The quick and dirty fix is changing the city name for each zip code into
something unique, like Savannah West side, Savannah Midtown, etc., but this
screws up mailing addresses based on the Site Locations table. What's the
best way to fix this?
have the same zip and two cities in my area (Savannah and Charleston) have
several zips, so neither the zip or the city name can be the primary index.
So, I gave them an autonumber primary key instead.
I have a table for work orders, and a table of job site addresses that
include a combo box that references another table named CityTimeMiledge with
the following fields: ID(autonumber), City(text), State(text), Zip(text),
Miledge(text), and Travel Time(text), with City as the bound column.
Everything works fine until I try to build a query using the table. The
query which searches out work orders by specific locations (which has a
combo box with a row source of SELECT[Site Locations].[Site Name], [Site
Locations].Address, [Site Locations].City, [Site Locations].[Phone Number]
FROM [Site Locations]; with [Site Name] as the bound column) will have
multiple entries for every site in Savannah, one for every zip code in
Savannah. If I change the bound column for City to the ID, the site
locations combo box shows the ID number in the address, not the city, and
the queries come up blank.
The quick and dirty fix is changing the city name for each zip code into
something unique, like Savannah West side, Savannah Midtown, etc., but this
screws up mailing addresses based on the Site Locations table. What's the
best way to fix this?