how to make below trigger works
the most important is that when defining trigger we don't know :NEW column names, and we generate it. I have a function that generate column names.
But the trigger i wrote do not work, the error message is
and it as about execute statement, cos trigger treats v1 as string not as :NEW.column_nam e
What i want to achieve is to write a trigger which is working even if i change column names.
Code:
create or replace trigger ..... v1 varchar(50); st varchar(50); ... begin .... v1=':NEW.'||'column_name'; execute immediate 'select '||v1||' from dual' into st dbms_output.put_line(st); ....
But the trigger i wrote do not work, the error message is
Code:
ORA-01008: not all variables bound
What i want to achieve is to write a trigger which is working even if i change column names.
Comment