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 John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IS NOT NULL problem

Status
Not open for further replies.

cpaige

Programmer
Jun 19, 2000
86
CA
Hey!
I have a query that needs to return all the records that have one field that is not null. If I run the query for records that are null it works fine, but not null just doesn't work. Nothing is returned. Here is my query:


SELECT
A.DATE, A.LEAVE, A.WORKCODE, A.COST, A.TIMEWORKED,B.DESCRIPTION
FROM
COSTLABOUR A,
WORKCODES B
WHERE
A.WORKCODE = B.CODE AND
( A.DATE BETWEEN '01-JAN-2001' AND '30-JUN-2002' ) AND
A.LEAVE IS NOT NULL
ORDER BY
A.WORKCODE ASC

Any ideas would be great

Thanks! :^)





Clayton T. Paige
claytonpaige@yahoo.ca

Programmer Extraordinaire

========================================================

"Who is General Failure? and Why is he reading my disk drive?"
 
At first glance I don't see anything wrong with your query. Have you considered the obvious - that no rows match your selection criteria?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top