Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query on null date

Status
Not open for further replies.

seb2

Technical User
Feb 6, 2002
27
US
Having problems with SQL for pulling all records where 'completed_date' NOT NULL.

Select*
from table
where table.complete_date = NOT NULL;

or
where table.complete_date = '';

Neither seems to work. What am I missing?
 
Try running your first query without the = in front of NOT NULL
 
Hi,

try:

Select * from MyTable where NOT table.complete_date IS NULL;

ps.
I just tested your other question about BETWEEN. It works for me:

Select * from tblstation where not [datetime] between '01/01/97' AND '01/01/02'


Sunaj
'The gap between theory and practice is not as wide in theory as it is in practice'
 
tlbroadbent is right on with the IS NOT NULL.
My apologies.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top