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

Home -> Community -> Usenet -> comp.databases.theory -> Re: Theoretical Basis for SELECT FOR UPDATE

Re: Theoretical Basis for SELECT FOR UPDATE

From: vc <boston103_at_hotmail.com>
Date: 4 Oct 2005 08:57:16 -0700
Message-ID: <1128441436.819898.177090@g44g2000cwa.googlegroups.com>

Tony Andrews wrote:
> vc wrote:
> > > Yes, it would: your syntax is not valid. The commas are not merely an
> > > syntactic alternative to semi-colons, they are semantically different
> > > too: they indicate that the two updates are to be treated as a single
> > > DML statement with no implicit ordering. You can't insert a call to
> > > procedure between the two updates - that is the point of having this
> > > syntax!
> >
> > Never mind 'print', is the update,select,update; sequence legal ?
>
> No. There is no "sequence" here - that is the whole point!

So, assuming t1 has no rows,

 insert into t1(x) values(1),update t1 where x=1 set x=2;

would have the same result as

 update t1 where x=1 set x=2, insert into t1(x) values(1);

Is that what you are saying ? Received on Tue Oct 04 2005 - 10:57:16 CDT

Original text of this message

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