title: If Not IsNull in ASP Classic
body: <p>I'm fairly new to asp and I've got a syntax error I would like help on if you can.</p>
  
  <p>I've got an ASP page that shows a table that pulls data from sql. Most of the data hasn't been populated yet so returns a NULL. The data type in question is numeric. I need to <code>FormatNumber</code> the <code>rs</code> when it is not null and not populate if it is.</p>
  
  <p>This is what I have</p>
  
  <pre><code>&lt;%=If Not IsNull(rs("ContractValue")) Then FormatNumber(rs("ContractValue"),0) end if%&gt;
  </code></pre>
  
  <p>But as mentioned, im getting a syntax error. </p>
  
  <p>What am i doing wrong?</p>