-
Between Statement Used with dates
I have a Client Side SQL Statement That Is asking For all Dates
Between Two dates.
Select * from table1 where Datefield1 between `1998-07-01` and
`1998-07-31`
datefield1 is a standard datetime type
The result set returns everthing except 1998-07-31
When I use the statement
Select * from Table1 where datefield1 <= `1998-07-01` and datefield1 =>
`1998-07-31`
Sql server returns everything including 7/31/98
Sql Server is evaluating 1998-07-31 as Jul 31 1998 12:00am
Is there a setting that I can toggle that will change this?
Also, I have tested this on another Server and the Between Statement is
evaluated correctly.
Thank you
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|