......
begin
select c_billdate
into varsenddate
from APLIUSER.TXD_SDLIST
where c_saleitem ------解决方案-------------------- c_saleid = csr.c_sditemid
and rownum<2;
exception
when others then
varsenddate := sysdate-10; --这里设置默认值
end;
...... ------解决方案-------------------- 我记得实在查询前给变量varsenddate先付个初始值,你那样select。。。into没查到数据就赋值会报错 ------解决方案--------------------
begin
varsenddate:='默认值';
select c_billdate
into varsenddate
from APLIUSER.TXD_SDLIST
where c_saleitem ------解决方案-------------------- c_saleid = csr.c_sditemid
and rownum<2;
......