1. We have moved to a new forum! There may be a few things not working properly so please let us know if you find a bug. Remember to use the bbCode [ sql ] tag for SQL statements.

How do I batch check 30 fields for NULL?

Discussion in 'SQL - Questions and Answers' started by ken du, Sep 28, 2006.

  1. ken du Guest

    Dialect: T-SQL
    I have say 30 fields and would like to batch check them for NULL in one SQL statement, is there a way? Or do I have to write something like the following for each single field:

    select field1 from table1 where isnull(field1);
  2. Dimitar Guest

    What exactly is the problem: the query needs to execute faster (much faster) or you do not want to write 30 separate tests for null?

Share This Page