If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
setting "date" criteria
When I set a criteria in a query "between [a] and [b]" to
prompt for dates "a" and "b" and then type in "8/16/04" for "a" and "8/31/04" for "b" when prompted, I get extraneous dates returned from dates prior to this range from 2002 and 2003. I If I set the criteria as: "between #8/16/04# and #8/30/04#" the dates are correctly displayed (no extraneous data is displayed from 2002 and 2003). Any ideas on how to get the correct dates displayed when prompted by the query? The date field in the query is the "general" date format. thanks much Jeff G |
#2
|
|||
|
|||
"Jeff G" wrote in message
... When I set a criteria in a query "between [a] and [b]" to prompt for dates "a" and "b" and then type in "8/16/04" for "a" and "8/31/04" for "b" when prompted, I get extraneous dates returned from dates prior to this range from 2002 and 2003. I If I set the criteria as: "between #8/16/04# and #8/30/04#" the dates are correctly displayed (no extraneous data is displayed from 2002 and 2003). Any ideas on how to get the correct dates displayed when prompted by the query? The date field in the query is the "general" date format. Open the parameters dialog in the query's design view and explicitly set the [a] and [b] parameters to Date DataTypes. Then try it again. Access might be making an improper assumption about the DataType and doing a Text comparison. -- I don't check the Email account attached to this message. Send instead to... RBrandt at Hunter dot com |
#3
|
|||
|
|||
Bingo! thanks for your help
-----Original Message----- "Jeff G" wrote in message ... When I set a criteria in a query "between [a] and [b]" to prompt for dates "a" and "b" and then type in "8/16/04" for "a" and "8/31/04" for "b" when prompted, I get extraneous dates returned from dates prior to this range from 2002 and 2003. I If I set the criteria as: "between #8/16/04# and #8/30/04#" the dates are correctly displayed (no extraneous data is displayed from 2002 and 2003). Any ideas on how to get the correct dates displayed when prompted by the query? The date field in the query is the "general" date format. Open the parameters dialog in the query's design view and explicitly set the [a] and [b] parameters to Date DataTypes. Then try it again. Access might be making an improper assumption about the DataType and doing a Text comparison. -- I don't check the Email account attached to this message. Send instead to... RBrandt at Hunter dot com . |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Using date range in query criteria | Kathi | Running & Setting Up Queries | 4 | August 30th, 2004 03:10 PM |
date criteria for report from form | Peter Woodhead | Setting Up & Running Reports | 5 | July 17th, 2004 12:19 PM |
Date Criteria on Query | xx | General Discussion | 1 | July 16th, 2004 01:26 PM |
Calendar Object | Steve | Setting Up & Running Reports | 1 | May 18th, 2004 04:44 PM |