alter table tablename move tablespace ts_name;
Code:
SQL> create user dbaf identified by dbaf;
User created.
SQL> grant connect, resource to dbaf;
Grant succeeded.
SQL> conn dbaf/dbaf
Connected.
SQL> create table dbforums (id number);
Table created.
SQL> select table_name, tablespace_name from user_tables;
TABLE_NAME TABLESPACE_NAME
------------------------------ ---------------------------
DBFORUMS SYSTEM
SQL> conn system/manager
Connected.
SQL> alter user dbaf
2 default tablespace users
3 temporary tablespace temp;
User altered.
SQL> conn dbaf/dbaf
Connected.
SQL> alter table dbforums move tablespace users;
Table altered.
SQL> select table_name, tablespace_name from user_tables;
TABLE_NAME TABLESPACE_NAME
------------------------------ ---------------------------
DBFORUMS USERS
Bookmarks