Criteria Question in Query Design

galvinjaf

Registered User.
Local time
Today, 10:16
Joined
Jan 5, 2016
Messages
108
I have two separate criteria for a simple query, but they run independant of eachother. I'm not sure how to combine the criteria so that if one criteria is met, it will display the second criteria.

I need to first enter the pay period ending date, then, if the tblAIB column comes back with 'used' in the column (from a lookup in the table) then display the record in the query, otherwise don't show me that employee.

There could be multiple pay period endings, but I only want to know who 'Used' a pass in certain pay periods.

I've attached a screen grab. Any ideas or help would be appreciated.

-J
 

Attachments

  • AIB_Query.JPG
    AIB_Query.JPG
    38.3 KB · Views: 90
I'm not sure how to combine the criteria so that if one criteria is met, it will display the second criteria.

Criteria isn't displayed, criteria is used. I don't fully understand what you want.

In the query you posted, for a record to be returned its [Owes Pass] value must be 'used' and it's [Period Ending] value must value between the input values.

Can you demonstrate with data what you want to occur? Your words don't really help.
 
you already have it, in your query.
 
I guess asked differently, Under the pay period ending column, my criteria is set to 'Between [Enter...' and my Owes Pass column is set to "used". When the query is run, what controls the order in which it checks the date / and then checks the 'used' field?
 
There is no order - both criteria have to be met in this example.
I think the DB engine will work out the most efficient way.

You could check by creating a sub query of one and link to the other.
 

Users who are viewing this thread

Back
Top Bottom