How do you get a lookup field to show as text in a report?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

My query pulls data from a table with a look-up field and the numeric ID is
what shows up in my report. How can I get the text that is linked to the
number to show up instead?
 
You can make a inner join with the table that has the text.
select textfield from table1 inner join table2_withtext where
table1.numericid = table2_withtext.numericid
 
The first thing you should consider doing is an exocism of all table lookups
in your database. Lookup fields defined at the table level are the creation
of the evil one. See the 2nd commandment here:

The Ten Commandments of Access
http://www.mvps.org/access/tencommandments.htm

Then, to get the looked-up value to display, add the lookup table to the
query, and add the appropriate field from this table. Note: You may need to
use an Outer Join, instead of the normal default Inner Join, especially if
your foreign key fields can be null.


Tom Wickerath
Microsoft Access MVP

http://www.access.qbuilt.com/html/expert_contributors.html
http://www.access.qbuilt.com/html/search.html
__________________________________________
 
Can you tell me exactly how to do that? My look-up table is Vendor with
Vendor ID and Vendor Name as fields, and the data table is POR with Vendor as
the look-up field.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top