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

Home -> Community -> Usenet -> c.d.o.server -> Re: Q: INSERT, UPDATE and how to catch rowid

Re: Q: INSERT, UPDATE and how to catch rowid

From: Gerard H. Pille <ghp_at_skynet.be>
Date: 1997/09/30
Message-ID: <01bccdd9$80e638a0$f11beec3@pcghp>#1/1

Hello Thomas,

Are you sure about the second "we" in "We can get the rowid of the last row we inserted (updated) into the table"?

I was afraid that I could get the rowid of someone else's insert, if it occurred between mine and the retrieval of the package variable.

-- 
Kind reGards,

Gerard
(ghp_at_santens.be; ghp_at_skynet.be)

Thomas Kyte <tkyte_at_us.oracle.com> schreef in artikel
<34361a91.7606767_at_newshost>...

> On 30 Sep 1997 09:15:36 GMT, "Gerard H. Pille" <ghp_at_santens.be> wrote:
>
> >But how would this trigger then pass the new rowid to the program that
made
> >the insert?
> --
>
> We can get the rowid of the last row we inserted (updated) into the table
> quite easily...
>
> try the following script, the concept is, we will use a package to
maintain a
> state; a trigger to populate the state. An after insert for each row
trigger
> can push the rowid of the newly inserted row into a package variable for
us. We
> can read the package variable and use it:
Received on Tue Sep 30 1997 - 00:00:00 CDT

Original text of this message

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