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: Bug or Misunderstanding ? Delete...Returning into does not work as I expected

Re: Bug or Misunderstanding ? Delete...Returning into does not work as I expected

From: <ctcgag_at_hotmail.com>
Date: 05 Feb 2003 00:40:05 GMT
Message-ID: <20030204194005.769$Ns@newsreader.com>


"kn" <keldnielsen<nope>@<nope>image.dk> wrote:

> > I would have thought that a 'returning...into' would behave the same
> > as 'select...into' does. It may be normal, but it doesn't seem
> > particularly intuitive or consistent.
> >
> then an update returning of say 3 rows. should raise to_many_rows ?

That's what I would have thought it would do, yes. If I wanted to return a value from all of the rows, I'd use BULK COLLECT. If I wanted it from none of the rows, I'd use an unadorned update. I really don't see why you'd want to update multiple rows and return a value from a random one of them. I'd assume "returning into" a scalar was an assertion that exactly one row will be affected, just as "select into" is.

Xho

-- 
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service              New Rate! $9.95/Month 50GB
Received on Tue Feb 04 2003 - 18:40:05 CST

Original text of this message

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