title: access 2013 query replace null to 0 does not work?
body: <p>I'm trying to create a query which I inserted some formulas but it has no result if there is any <code>NULL</code> in cells involved in a formula. I tried to replace <code>NULL</code> to <code>0</code> (not necessary to show the number <code>0</code>, just need a value so that the formula can work) with this <code>SELECT IIF(ISNULL([field]), 0, [field]) FROM [table]</code> but I don't know how to write it correctly in SQL view. Here is the entire SQL code: <br/></p>
  
  <pre><code>SELECT [LISTING MASTER].Broker, [LISTING MASTER].Type,
  [LISTING MASTER].[TransID], [LISTING MASTER].ACTIVE, 
  [LISTING MASTER].[CANCELLED - CLIENT], [LISTING MASTER].[CANCELLED - TEAM], 
  [LISTING MASTER].EXPIRED, [LISTING MASTER].[OFF MARKET], 
  [LISTING MASTER].PENDING, [LISTING MASTER].[SOLD - EXTERNAL], 
  [LISTING MASTER].[SOLD - INTERNAL], [LISTING MASTER].UNSIGNED, 
  [ACTIVE]/[TransID] AS active1, [CANCELLED - CLIENT]/([TransID]-[ACTIVE]) AS CC2, 
  [CANCELLED - TEAM]/([TransID]-[ACTIVE]) AS CT3, [EXPIRED]/([TransID]-[ACTIVE]) AS expired4
  FROM [LISTING MASTER];
  </code></pre>
  
  <p>How can I change all the <code>NULL</code> to <code>0</code>? More particularly, I need <code>[ACTIVE]/[TransID] AS active1, [CANCELLED - CLIENT]/([TransID]-[ACTIVE]) AS CC2, [CANCELLED - TEAM]/([TransID]-[ACTIVE]) AS CT3, [EXPIRED]/([TransID]-[ACTIVE]) AS expired4</code> this part works.
  If someone could fix it and paste the whole code so that I can just paste it in my SQL view, it would be great appreciated! I barely know coding... Thanks a lot.</p>
  
  <p><a href="https://i.stack.imgur.com/1jR8E.png" rel="nofollow noreferrer">What the query looks like</a></p>
  
  <p><a href="https://i.stack.imgur.com/h2ouy.png" rel="nofollow noreferrer">Design view</a></p>