> Hi Doug i am not sure what you mean. In the customer table the city and
> state
[quoted text clipped - 36 lines]
>> > Thanks
>> > Ian
Hi peter here is the sql used for the query to get the information for the
mailing labels
SELECT Customer.Sal, Customer.[ContactFirst Name], Customer.ContactLastName,
Customer.CompanyName, Customer.Number, Customer.StreetName, Customer.Suite,
Customer.City, Customer.ProvState, Customer.PostalZip, Customer.Inactive
FROM Customer
WHERE (((Customer.Inactive)=No));

Signature
Thanks
Ian
> If your "base table" (probably "customer") has lookups defined in Access,
> all bets seem to be off. In theory, if you have a query along the lines of
[quoted text clipped - 48 lines]
> >> > Thanks
> >> > Ian
Peter Jamieson - 17 Nov 2006 22:22 GMT
Hi Ian,
Typically, in your Customer table, you will actually have a City /ID/ of
some kind, and perhaps a "ProvState" /ID/ of some kind, and the information
for that City will be in another table (perhaps called "City") and so on. I
can't know for sure because eevry database is dfferent.
But let's suppose you have tables for Customer, City and State.
Let's suppose that your Cusstomer table's City column actually contains the
primary key for a table called City, and that that table's primary key id
called ID. Lets' assume that the City table has a column called CityName
which contqains the City's name, which is what you actually expect to see in
"Customer.City")
Let's assume similar stuff about a table called "State"
Phew!
Then try SQL like
SELECT Customer.Sal, Customer.[ContactFirst Name], Customer.ContactLastName,
Customer.CompanyName, Customer.Number, Customer.StreetName, Customer.Suite,
City.CityName, State.StateName, Customer.PostalZip, Customer.Inactive
FROM Customer, City, State
WHERE (Customer.Inactive=No)
AND Customer.City = City.ID
AND Customer.State = StateID
Just my 2c-worth.
Peter Jamieson
> Hi peter here is the sql used for the query to get the information for the
> mailing labels
[quoted text clipped - 67 lines]
>> >> > Thanks
>> >> > Ian