Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

PLS-00049: bad bind variable problem

409873Nov 27 2003 — edited Nov 28 2003
I am writing a trigger, before I delete a patron, i have to check if the patron already returned all library books. the code like:
create or replace trigger patron_bef_del_row
before delete on BORROWERS
for each row

declare
num integer := 0;

cursor plc is
select *
from BOOK_LOANS
where card_id = :old.card_id;
----
I got:
Warning: Trigger created with compilation errors.

SQL> show errors
Errors for TRIGGER PATRON_BEF_DEL_ROW:

LINE/COL ERROR
-------- ---------------------------------------------
7/19 PLS-00049: bad bind variable 'OLD.CARD_ID'

What is wrong, please help and thanks!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 26 2003
Added on Nov 27 2003
1 comment
164 views