title: Handling blank query results, ISNULL(NULLIF())
body: <p>Im trying to return the results of a query into a variable  to I am able to use it in a insert statement. However my select keeps returning null even though I believe I have the <code>ISNULL(NULLIF())</code> set up correctly.</p>
  
  <pre><code>declare @test varchar(10)
  
  set @test =  (select ISNULL(NULLIF(discnumber,''),'NA')
  from discmaster
  where meteredfilename =  '3501' or nonmeteredfilename='3501')
  
  select @test
  </code></pre>
  
  <p>It seems correct but still returns a <code>NULL</code> value. Would you Select Case but not 100% sure on that method either.</p>