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

Home -> Community -> Usenet -> c.d.o.misc -> Re: massive delete

Re: massive delete

From: Jorge <cafelito_at_---NO---SPAM---yahoo.com>
Date: Thu, 23 Sep 1999 15:41:54 +0200
Message-ID: <7sdave$coq$1@diana.bcn.ttd.net>


>1. Rather than the cursor, you could delete with the help of the rownum
>variable as follows:
> SQL> delete from massive_table where rownum<10001 and ....;

Good idea... I'll have to count how many rows to delete and loop N/10000 times
over "delete from xxxxx where (criterions) and rownum<10001;

>2. If you want to delete all rows in the table use the truncate
>tablestatement:
> SQL> truncate table massive_table;

Yes, but many rows can't be deleted from this table.

One question more, will "truncate " command increase data fragmentation?

thanks for all the replies.

    Jorge Received on Thu Sep 23 1999 - 08:41:54 CDT

Original text of this message

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