Report shows ID numbers instead of text

G

Guest

I have a report based on a table. The table shows instructor names in the
"InstructorID" field. In the report, this field shows their underlying
autonumber. How do I make the report show the names instead? Thanks in
advance.

bbarkman
 
D

Douglas J. Steele

Sounds as though you've used the useless Lookup Field "feature". While your
table may look as though you're storing the instructor names, you're
actually storing the Id. You need to create a query that joins your two
tables together so that you can get the name from your second table, and use
that for your report.
 
G

Guest

Report controls have a Control Source property that tells Access where to get
the data you're interested in. It must be set to "InstructorID". To print
the name, base your report on a query that links your table to the
Instructors table, and include the InstructorName field in the query
selection. Then you can change the control's ControlSource to the name of
this field.

As an aside, this is good, because it means you are only storing the foreign
key InstructorID in your table, which is how it ought to be. The reason your
form displays the name instead is because your combo box is displaying the
first non-zero-width column. Look at your combo box' properties. I suspect
Bound Column is set to 1, meaning the first column is what is stored in the
underlying field, and your ColumnWidths are set to 0";x", etc., where x is
some value.

Hope that helps.
Sprinks
 
Joined
Jul 7, 2014
Messages
1
Reaction score
0
Sounds as though you've used the useless Lookup Field "feature". While your
table may look as though you're storing the instructor names, you're
actually storing the Id. You need to create a query that joins your two
tables together so that you can get the name from your second table, and use
that for your report.

Hi Doug, I've been having this problem too. I've read a lot of bad reviews about Lookup Fields. What I like about them is that they standarize the input. So, if we are not to use Lookups, what can we use instead of it?

For example, I have a restaurant, I want a Lookup field pointing to tblWaiters so there is no mistake in the moment someone fills this cell, and very important too, if I want to add more waiters is very easy to mantain.

What are your thoughts on this?:blush:
 

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

Top