Date range queries

P

Pat Hughes

I'm having problems with date range queries. Can I make these queries when
the person who built the database used "Text" as the "data type" for the date
field in the table? In my querie I am using {Between "07/01/2008" And
"9/30/2008"} but the brackets are not a part of it. But I am getting
October's data also. (The data starts with July so I don't have to worry
about before July.
 
J

Jeff Boyce

Pat

"07/01/2008" is NOT a date, it's a text string. In Access, #7/1/2008# is
interpreted as a date/time value.

Since what you have stored is text, naturally "10/..." happens before
"9/..." (one comes before nine).

Consider converting those psuedo-dates to actual date/time values, then
sorting by the date/time value.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top