Date Range Crossover

ReAn

Dangerous Programmer...
Local time
Yesterday, 20:34
Joined
Jun 25, 2004
Messages
250
Trying to pull up records that have any scheduled day/time in another range of date/times.

Ok:

In my Table i have Scheduled Start and Scheduled Finish, and on my form i have Period Beginning and Period Ending. I need to pull up any records that are scheduled to be active between Preriod Beginning and Preiod End

Any suggestions?
 
ScheduledStart <= PeriodEnding AND ScheduledFinish >= PeriodBeginning
 
What if they overlap? Like, this:

Daterange1:__||||||||||||||||____
Daterange2:________||||||||||||||
 
Did you test it? It should include those records, as they are active during the period (which is what you wanted, right?).
 

Users who are viewing this thread

Back
Top Bottom