Issue with NULL not allowing a calculation to happen

  • I have such a situation I use this command to basically allow division by 0. So far it was working just fine, but now it for some reason no longer works well for me.

    SET ARITHABORT OFF 
    SET ANSI_WARNINGS OFF

     

    I am trying just to make a simple calculation like this

     

    sk.OH + sc.QTY AS 'Projected Available Inventory (In DC)'

     

    However, my output looks like this. It basically destroys calculation because one of the values is NULL. In this case "On Order" has a NULL value.

    So my question is is there a way to allow a calculation happen if one of the values is not given?

     

    Issue1

  • Ohh I figured that, my apology, i will appreciate if it can get removed.

  • COALESCE(column,0) ?

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply