Help require with trigger and CLOB
zooidJun 19 2010 — edited Jun 28 2010Hi everyone,
I have a define a temporary global table to collect data from an apex page and then I use a trigger to insert the collected data into different permanent tables on the same db.
One of the fields on the temporary table is a CLOB and I seem to be doing something wrong, as the CLOB on the permanent table is not populated??
I have read the Oracle Large Object PDF and I can not seem to find what I am doing wrong.
I have tried a number of things.
What I like to do in the before insert trigger of the temporary tables is something like this:
DECLARE
tmp NUMBER;
BEGIN
tmp := :NEW.DB_ID;
INSERT INTO AA (DB_ID, DOC_DATA )
VALUES (:NEW.DB_ID, EMPTY_CLOB() );
UPDATE AA
SET DOC_DATA = :NEW.DOC_DATA
WHERE DB_ID = tmp;
END BI_AB;
I someone could put me on the right track i would much appreciate it.
Regards
Daniel