ORA-01403未找到數據的錯誤。其中jkcode,serialid是varchar2(64)。語句是這樣的:
select
jk_code,serial_id into jkcode,serialid
from
contract_account,customer,mp,meter
where
contract_account.customer_id=customer.customer_id and contract_account.contrac_id=mp.contrac_id
and mp.mp_jd=meter.mp_id and meter.meter_id=meter_cursor.newmeterid;
原來根據某些 meter_cursor.newmeterid查不到jk-code與serial-id即查到0條,我猜測在into的時候有問題。具體為什么不行我 也不是很曉得。但是能知道要是查不到信息into就提示上面的錯誤。解決辦法很容易就是將這個語句復制一下,先計算count(*)如果為0就不執行,如 果》0就執行上面的語句。
