Re: Moving tables and indexes

From: Connor McDonald <connor_mcdonald_at_yahoo.com>
Date: Mon, 27 Nov 2000 18:11:15 +0800
Message-ID: <3A223343.7F57_at_yahoo.com>


David Grzebien wrote:
>
> Bjorn,
>
> This stuff can be found in the Oracle manuals.
>
> The syntax for moving an index is
>
> ALTER INDEX <index_name> REBUILD
> TABLESPACE <new_tablespace_name>
> STORAGE ... -- If desired
>
> Depending on the version of Oracle, you can move tables in different manners.
> Prior to 8i (I believe) you can move tables by performing an export and import
> of the data. With 8i, you can issue the ALTER TABLE <table_name> MOVE
> statement. I am not sure of the syntax, but I do know it is possible.
>
> Dave Grzebien
> Expert Technical Consultants, Inc
> dave_at_etci.net
>
> "Bjørn Sørensen" wrote:
>
> > Can somebody tell me how I can move tables and indexes from one tablespace
> > to another ?
> > The problem is :
> > I want to move one big table to a new tablespace and the database indexes to
> > a second new tablespace.
> > How do I do this and will the indexes be rebuilt after moving them ? If not,
> > how can this be done ?
> >
> > Any help would be great. Thanks
> >
> > bjorn
> > bjoesoe_at_online.no

Your syntax is just about spot on...

alter table BLAH move NEW_TABLESPACE;

HTH

-- 
===========================================
Connor McDonald
http://www.oracledba.co.uk (mirrored at
http://www.oradba.freeserve.co.uk)

"Some days you're the pigeon, some days you're the statue"
Received on Mon Nov 27 2000 - 11:11:15 CET

Original text of this message