Re: UPDATE with Oracle ??? with join ???
From: Daniel Morgan <damorgan_at_x.washington.edu>
Date: Wed, 19 Nov 2003 14:40:19 -0800
Message-ID: <1069281641.725087_at_yasure>
Date: Wed, 19 Nov 2003 14:40:19 -0800
Message-ID: <1069281641.725087_at_yasure>
Malcolm Dew-Jones wrote:
> Daniel Morgan (damorgan_at_x.washington.edu) wrote:
>
> : SQL> UPDATE (SELECT * FROM channels WHERE channel_desc = 'Catalog')
> : 2 SET channel_desc = 'X';
>
> That's lovely! though I guess it's new in version 9.
Not as far as I know. Should have been around since at least 8.0: Likely earlier.
> You check your criteria using the 100% safe select, and then run the
> _identical_ statement in the "dangerous" step of modifying data.
>
> I plan to lookup
>
> DELETE FROM (SELECT...)
>
> to see if that works
>
> though direct answers as to whether that is also supported would be
> available for all to read.
Best thing to do is just create a small temp table and try it.
-- Daniel Morgan http://www.outreach.washington.edu/ext/certificates/oad/oad_crs.asp http://www.outreach.washington.edu/ext/certificates/aoa/aoa_crs.asp damorgan_at_x.washington.edu (replace 'x' with a 'u' to reply)Received on Wed Nov 19 2003 - 23:40:19 CET