This content has been marked as final. Show 3 replies
try to declare default for the sum variable as 0
or try to check the value before u do the calculation if it is null assign 0 to sum variable.
you can try to use decode function for setting 0 for the null values
or Checking for Nulls before +/- http://docs.oracle.com/cd/E10415_01/doc/bi.1013/e12187/T421739T481157.htm#4535384
Declear your var1 and 2 values as "0" while defining the Variables.