Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 select query where condition date field null or no

Author  Topic 

reddymade
Posting Yak Master

165 Posts

Posted - 2006-01-12 : 11:23:08
I have the following select query, where condition checking the date field <> "" or ="" but in the database table it shows this:" / / "

SELECT TAB_ccsNetSU.SUNumber, TAB_ccsNetSU.SUTitle where TAB_ccsNetSU.ReceivedDate <> "" and TAB_ccsNetSU.ReviewDate = ""

How to check the date is there or not.

Thank you very much for the information.

cshah1
Constraint Violating Yak Guru

347 Posts

Posted - 2006-01-12 : 11:29:29
use ISDATE to determine whether the expression is the valid date or not.


WHERE ISDATE(TAB_ccsNetSU.ReceivedDate) = 1 should bring all the valid dates records
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2006-01-12 : 12:43:02
Why do people refuse to use proper data types ?
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2006-01-13 : 02:36:43
quote:
Originally posted by jsmith8858

Why do people refuse to use proper data types ?


Particularly on Date

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -