1 Reply Latest reply: Jun 12, 2015 9:17 AM by Stefan Wühl RSS

    Creating a script function that also returns NULL




      In my model I try to create a variable that contains a formula that returns the content from a table given a current selection, but i also want it to return the NULL (blank) value when the cell is blank.


      Now, my script looks like this:


      let vVariable = 'sum({$<KV_Start_Date = {"< =' & ' $ ' & ' (=min(Date))"}>} KV_Actual_Value)


      In practice, the data table containing KV_Value_Actual only have one cell for each selection. Thus, I'm actually only trying to get the content of the cell in the table returned by the function.


      I find that the "sum" function returns blank cells as 0, not Null().



      This is an example of the content I want the formula to return:


      SelectionKV_Value_ActualWhat I want the formula to return




      Appreciate all help