Local Array laSumf1[1] laSumf1[1] = 0 && In case if cstView has no records SELECT f1, Sum(f3) ; From cstView ; Group By 1 ; Into Array laSumf1 * The number of records retrieved by select * is stored in system variable _TALLY. * If it's zero than your view doesn't have any records, it's empty Thisform.aSumf1 = laSumf1