if n_sxjjr = 0 thenselect count(1) into n_jjrcount from gh_jjr where rq in (select to_char(arg_ghrq, 'MMDD') from dual) and rownum = 1;if n_jjrcount = 1 thenn_sxjjr := 1;end if;
n_sxjjr=0时,统计记录数量。如果n_jjrcount 是1,默认n_sxjjr 为1.