I have a partitioned table that belongs to tablespace report. I want to move it to tablespace record instead.
One possibility is to drop the table and
You can either do it with PL/SQL or generate the statements with sql. I decided to generate the alter table statements with simple SQL:
--set linesize
set lines 100
--This Query generates the alter table statements:
SELECT 'ALTER TABLE '
||table_name
||' MOVE PARTITION '
||partition_name
||' TABLESPACE REPORT;'
FROM all_tab_partitions
WHERE table_name = 'requestLog';
You can execute the output from the previous statement.
Every user has a default tablespace. New database objects are created in that default tablespace if nothing else is specified on creation/alteration