Need null values for several fields in db

  • Thread starter Thread starter shahnaz
  • Start date Start date
S

shahnaz

I have an equipment inventory db. I need to run a query that would give me
the records that contain null values in several of the fields. I have run a
successful query to return records that have a null value in one field but
don't know how to combine so that query returns records that also have null
values in other fields or any other fields.

Please advise
 
You join the seperate queries with a UNION.

SELECT * From YourTable WHERE YourField Is NULL
UNION
SELECT * From YourTable WHERE YourField2 Is NULL
UNION
SELECT * From YourTable WHERE YourField3 Is NULL ;

You can't do this from the normal query grid. Rather you probably need to do
it in the SQL view typing in something like above.

One big point here: If you have to do things like this, there's a very good
chance that your data isn't properly normalized and your tables set up less
than optimum.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Null or NOT in another table 4
counting Null fields 3
Null value question 2
Testing for null 4
select query not null 7
#error - Blank 3
Long list of fields, how to check if either is null 3
Joning on null value 3

Back
Top