>select sum(apr) from crsRpt where fisyear = fy into array a1 >if _tally>0 > replace aprTotal with nvl(a1,0) >endif >select sum(may) from crsRpt where fisyear = fy into array a1 >if _tally>0 > replace mayTotal with nvl(a1,0) >endif >select sum(jun) from crsRpt where fisyear = fy into array a1 >if _tally>0 > replace junTotal with nvl(a1,0) >endif>>Given a sequence like this
>>select sum(apr) from crsRpt where fisyear = fy into array a1 >>replace aprTotal with nvl(a1,0) >>select sum(may) from crsRpt where fisyear = fy into array a1 >>replace mayTotal with nvl(a1,0) >>select sum(jun) from crsRpt where fisyear = fy into array a1 >>replace junTotal with nvl(a1,0)>>you would think that if the select came up empty the array a1 would become null. However I find that instead of being reset to null the array simply carries over with its prior value. Is there a way to insure that it will be null if the select is empty?