Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Getting the identity of the row just inserted
I think that this must be like that:
DECLARE
v_variable number(5)
BEGIN
SELECT your_sequence.next INTO v_variable FROM DUAL;
insert into your_table values
(v_variable, ...);
do want you want to do with v_variable;
END;
Uzytkownik "Kathinka Diehl" <kathinka_at_rrr.de> napisal w wiadomosci
news:m7i1bt4d2rhfnopm190rrgc3rvdl3k6aeg_at_4ax.com...
> Einar Magnus Råberg <einarmr_at_tihlde.org> wrote:
>
> > OK, I'm using Oracle 7.
> >
> > Could you give me som examples?
>
> DECLARE
> v_variable number(5)
> BEGIN
> v_variable := your_sequence.next;
>
> insert into your_table values
> (v_variable, ...);
>
> do want you want to do with v_variable;
> END;
>
> Regards, Kathinka
>
> --
> Oracle 7.3.4.5 * MS SQLServer 7 * Access2000 * Windows NT * sigh
Received on Thu Mar 15 2001 - 10:20:40 CST
![]() |
![]() |