2
create or replace trigger insert_catid
before  insert or update or delete on categories
for each row
begin
SELECT categories_seq.NEXTVAL INTO :NEW."cat_uid" FROM DUAL;
end;

i am using oracle 11g. I am compiling this trigger it is giving me error of

Error(7,36): PLS-00049: bad bind variable 'NEW.cat_uid'

please suggest me about this error

1 Answer 1

2

It means there is no column "cat_uid" in the table. By putting the name inside double quotes you have made it case-sensitive, so if your column is actually CAT_UID this will not work, i.e. you need to remove the quotes.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.