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: TRUNCATE v DROP TABLE question

Re: TRUNCATE v DROP TABLE question

From: michael ngong <mngong_at_yahoo.com>
Date: 4 Feb 2002 09:01:22 -0800
Message-ID: <ecf365d5.0202040901.631fdd26@posting.google.com>


marc_at_marcblum.de (Marc Blum) wrote in message news:<3c5d72d7.1947860_at_news.online.de>...
> On Sat, 02 Feb 2002 04:14:16 GMT, gl <jogret_at_hotmail.com> wrote:
>
> >Now doing the drop table would be very close to the truncate (DDL also),
> >except it will do one other thing, it will remove all the structures.
> > That means it will release all the extents that are allocated to the
> >table as well as the indexes, and the data will go the same route as the
> >truncate (non-recoverable & immediate). The bad thing with this that
> >everything in the tablespace will be release, and when you go redefining
> >the table, you'll get extents that are available and not necessarily
> >what was used last. This could lead to a fragmentation problem in your
> >tablespace.
>
> consider TRUNCATE TABLE <tab> REUSE STORAGE;
>
> => data will be trucated, but extents remain allocated
>
> regards
> Marc Blum
> mailto:marc_at_marcblum.de
> http://www.marcblum.de

If your table has many rows you may need to recreate  the index when you repopulate it
Michael Ngong (Sr DBA) Received on Mon Feb 04 2002 - 11:01:22 CST

Original text of this message

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