Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Help!! Trigger is not fired when updating LOB values

Help!! Trigger is not fired when updating LOB values

From: <simrion_at_263.net>
Date: Tue, 09 Mar 1999 05:42:19 GMT
Message-ID: <7c2cbq$ivt$1@nnrp1.dejanews.com>

I write a trigger on an oracle table which has a LOB column, but when I update the LOB values,the trigger is not fired!

SQL>create table technote(author varchar2(100),article CLOB);

SQL>create or replace trigger technote_tri   2 after insert or update or delete on technote   3 begin
  4 -- do some process
  5 end;
  6 /

then I write an application to test the trigger.

void load()
{

   char Aut[100];
   varchar the_string[32768];
   OCIClobLocator *lclob;

...

   EXEC SQL INSERT INTO technote(author,article)     VALUES (:Aut,EMPTY_CLOB()) RETURNING article INTO :lclob;

   EXEC SQL LOB WRITE ONE :amt FROM :the_string INTO :lclob AT :offset ;
...

}

Inserting manipulation fires the trigger, but the updating manipulation(writing CLOB) doesn't fired the trigger. So, I can't get the last CLOB value. How I can avoid this??

I get some information about it in the Oracle tech article: using OCI functions or the DBMS_LOB package to update LOB values or LOB attributes of object
columns will not fire triggers defined on the table containing the columns or the attributes.

Any help will be greatly appreciated.

Simrion

-----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own Received on Mon Mar 08 1999 - 23:42:19 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US