dbIsNull

Top  Previous  Next

Syntax

INT = dbIsNull(hstmt as INT,column as INT)

Description

Tests a column in a record from a result set for NULL.

Parameters

hstmt - A statement handle returned by dbExecSQL or dbPrepareSQL.

column - Ones based column number to test.

Return value

TRUE if the column is nullable and currently set to NULL.  FALSE otherwise.

Remarks

An alternative to using the pReturn variable set when binding a column. Some database drivers may not support the dbIsNull command. At least on dbGet or dbGetNext call must have been performed on the result set prior to using this command.

See Also: dbBindVariable

Example usage

WHILE dbGet(hstmt)
    PRINT "ID:",Address_ID
    PRINT first," ",last
    PRINT street
    IF dbIsNull(hStmt,5) = FALSE
        PRINT city, "," ,state, " ", zip
    ENDIF
    PRINT
ENDWHILE