I've the SSRS Expression that is provided below. The issue with that expression is that the last column sometimes shows #VALUE!
when the 1st column value is NA
. It is basically failing to calculate.
How can I fix this expression so that it shows the correct numeric value? One possible solution is to substitute 0
for NA
, but how can I achieve this ?
Expression:
=iif(Fields!NumType.Value = "1",iif(reportItems!txt_Current_Filing_Firm.value = "","0",reportItems!txt_Current_Filing_Firm.value),"1") - IIF(Fields!NumType.Value = "1",iif(reportitems!txt_Compare_Filing_Firm.value = "","0",reportitems!txt_Compare_Filing_Firm.value),"1")
Current Output in SSRS:
Column 1 | Column 2 | Column 3
NA 3456.00 #VALUE!
NA 347856.00 #VALUE!
NA 98763456.00 #VALUE!
NA 33456.35 #VALUE!
Expected Output in SSRS:
Column 1 | Column 2 | Column 3
0 3456.00 -3456.00
0 347856.00 -347856.00
0 98763456.00 -98763456.00
0 33456.35 -33456.35