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: Delete whole table in one go versus batches

Re: Delete whole table in one go versus batches

From: Niall Litchfield <n-litchfield_at_audit-commission.gov.uk>
Date: Tue, 20 Aug 2002 11:01:27 +0100
Message-ID: <3d621378$0$238$ed9e5944@reading.news.pipex.net>


"Norman Dunbar" <Norman.Dunbar_at_lfs.co.uk> wrote in message news:E2F6A70FE45242488C865C3BC1245DA70287E31D_at_lnewton.leeds.lfs.co.uk...
> Ender,
>
> Richard's advice is, as ever, excellent. However, in his haste to return
> the the CD player to listen top yet another David Bowie CD, he neglected
> to add one final stage to the procedures. I attach it here for
> completeness :
>
> if your DBA refuses to truncate table for you, simply say "ah well, I
> better go 'DELETE FROM ,table>' but if I'm not sure, I might do a
> rollback when It finishes" - and that will take almost as long. :o)
> How to wind up a DBA in one easy lesson.
>
> Enjoy :o)

Though it won't work in Ender's case you forgot the more general advice to issue LOCK TABLE ... EXCLUSIVE at the start of the transaction just in case :-( - not to mention the need to set the process running and go off to a meeting where you are uncontactable before you get to the commit/rollback stage.

--
Niall Litchfield
Oracle DBA
Audit Commission UK
*****************************************
Please include version and platform
and SQL where applicable
It makes life easier and increases the
likelihood of a good answer

******************************************

still regretting the absence of kill user <blah>; in the SQL language.
Received on Tue Aug 20 2002 - 05:01:27 CDT

Original text of this message

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