Article ID: 128072
Article Last Modified on 2/12/2000
SELECT * FROM mytable WHERE cFld1 = .NULL.Null should be used when a value is missing, irrelevant, or unknown. When any conditional expression encounters a null value, a .NULL. will be returned. A value of true (.T.) or false (.F.) cannot be returned if part of the expression is unknown or null. The expression in the above example, cFld1 = .NULL., will never evaluate to True, instead it will evaluate to .NULL. and as a result no records will be returned.
SELECT * FROM mytable WHERE cfld1 IS NULLIn this example, whenever cfld1 is .NULL., the IS NULL clause will cause the SELECT command to return a .T. and the desired records.
Additional query words: VFoxWin
Keywords: KB128072