title: SQL case statement - Multiple conditions
body: <p>I am writing a case statement where I need to check columns and assign a value . But what if a row qualifies for multiple cases ? For example in following table I want assign a bucket when COLA and/or COLB is null ; so in first case both are NULL , so how will I tell SQL case statement to assign "Both are NULL " when COLA and COLB are null. I can easily assign when COLA or COLB is null . At my work I am checking 8 columns , so I need to find every combination and right case for that ? There has to be an easy way .</p>
  
  <pre><code>**RowNumber     COLA                  COLB                Case**
  1                   Null                  Null               **Both are NULL** 
  2                   Null                  B                        A is null
  3                   A                 Null                 B is null 
  4                   AA                BB                   NULL
  5                   CC                Null                 B is null 
  </code></pre>