Click to See Complete Forum and Search --> : Skip Blank Records


theflyingminst
03-16-2009, 12:05 PM
Hi I've got my SQL statement set up as follows.

strSQL = "SELECT * FROM Table WHERE Column IS NOT NULL Order by CLng(Column_Query) Asc"

This works as long as there was never anything in the field to begin with, but if a field is updated to be blank at a later date some errors come up..

Is there a way to skip blank AND null fields, like can I add something to this statement to do that?

By the way I am using classic ASP and Access


Thanks so much

Phill Pafford
03-16-2009, 01:40 PM
strSQL = "
SELECT *
FROM Table
WHERE Column IS NOT NULL
AND Column != ""
ORDER BY CLng(Column_Query) ASC
"

theflyingminst
03-16-2009, 02:02 PM
Hi, thanks I really appreciate it!