![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have a DateTime Field in a query [DateTime] . I'm trying to set up a criteria that will show only events before a particular date. To do this I set the criteria to: <[enter Time and Date] How ever no matter what date and time I enter the result is nothing. When I tried the opposite to get only events after a particular date and time (ie. >[enter Date and Time] ) It returned every entry in the query no matter what date and time I enter. a sample of the data field is as follows: DateTime __________________ 07/02/2003 8:00 AM 07/02/2003 12:00 PM 07/03/2003 10:00 AM 07/03/2003 2:00 PM 07/04/2003 1:00 PM 07/04/2003 5:30 PM with criteria is set to: <[enter Time and Date] If I enter 07/03/2003 12:00 PM It returns no results with criteria is set to: >[enter Time and Date] If I enter 07/03/2003 12:00 PM It returns all 6 results Can someone please help me out. I've lost a lot of hair this week. Thanks, Rob |
#3
| |||
| |||
|
|
Access appears to be misunderstanding the data type somewhere. In query design view, select Parameters on the Query menu, and delcare your parameter (using exactly the same spelling). This way you can specify its data type. |
![]() |
| Thread Tools | |
| Display Modes | |
| |