Date Formats in queries

G

Guest

Hi,

I have a problem regarding date formats when I run a query. Basically I pass
two dates to a query in the format #dd/mm/yyyy# as a date range for my query.
The problem I am having is that if the date is, for example, 01/11/2004 (01
November 2004) it takes it as 11 January 2004 (mm/dd/yyyy) and if I pass in
30/10/2004 it reads it correctly as 30 October 2004. Is there a way around
this?

Example query:
SELECT DISTINCT (Client) FROM Trip WHERE Date1 >= #01/11/2004# AND Date2 <=
#11/11/2004#

Thanks in advance for your help.

Jen
 
T

Terry

Hi Jen,

You need to format your dates as mm/dd/yyyy before using them in the query,
it will work just fine after that.

Regards
 

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