query 2nd column of a table TIA

  • Thread starter Thread starter Mike D.
  • Start date Start date
M

Mike D.

I want to do a query of a field that has 2 columns. I'm
looking to just get the 2nd column searched, but it's
just looking in the 1st column.

Example picklist -
John | 1st shift
Mike | 2nd shift
Lisa | 1st shift

I want to return results that are just "1st shift"

TIA!

Mike D.
 
Mike

Create a new query in design mode. Add the table. Select the second field
for display. Run the query.

Good luck.

Jeff Boyce
<Access MVP>
 
Are you saying you have a 'lookup' field in a table? i.e. in datasheet view
you see a combo box that when dropped down looks like your sample?

If so, you likely will regret having a lookup in a table. You should save
these for when you create a form for your table. More details at
http://www.mvps.org/access/lookupfields.htm

To answer your question, create a new query and add two tables - the one
with this picklist, and the second table that you 'looked' up to.

Add the fields you want to the grid, and include the field from the lookup
table that has the shifts in it. Beneath this column, in the criteria row
put
1st shift
 
Back
Top