PDA

View Full Version : Using Query to check if fields have data..



Austin
09-14-2008, 06:35 PM
I have about 15 different fields that I need to check and see if they have any data at all. I need to build a report that shows all of the primary key's for the fields that DO have data in the 15 fields.

I've been trying to do a

Expr1: NOT IsNull(Fieldname1)

but that is not working.

I'm trying to think my way through other ways to do this, but I think this is the only way. Any ideas?

CreganTur
09-15-2008, 05:37 AM
I've been trying to do a

Expr1: NOT IsNull(Fieldname1)

but that is not working.


The SQL syntax is incorrect. To check it you would need to use (fieldname1) Is Null

At first blush I'm thinking that you can do what you want using something like this in the WHERE clause:
WHERE Field1 Is Null Or Field2 Is Null Or Field 3 Is Null...