Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Moving tables from a tablespace
in the destination tablespace, create a user to "receive" the tables. in the source tablespace, grant select on the tables to this user. in the source tablespace, create yourself a script something like
select 'create table ' || table_name || ' as select * from ' || owner || '.' || table_name from all_tables
this script produces something like this:
'CREATETABLE'||TABLE_NAME||'ASSELECT*FROM'||OWNER||'.'||TABLE_NAME
SPOOL this to a file on your client.
login as the user (into the detination tablespace)
START this file.
<raju_pillai_at_yahoo.com> wrote in message news:7voea8$4og$1_at_nnrp1.deja.com...
> We have a bunch of tables in a single tablespaces and I would like to
> move them to different tablespaces. I have already created the necessary
> tablespaces for those tables including tablespaces for their indexes.
> Now I am ready to move the tables and the data. How can I do this in the
> most efficient way. I also need the indexes and contraints for those.
> Can anybody suggest me the best way to accomplish this.
>
> Any input is greatly appreciated.
> Thanks
>
> Raju
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Wed Nov 10 1999 - 17:44:30 CST