Drop a table and deallocate space

13 Dec

Drop table, free up space, in oracle 10g.

When we use normal drop table command, it drops the table, but it does not free up the space from tablespace. It keeps it into the recycle bin of the database. In order to free the tablespace used by the table to be droped we use the following command.

SQL> drop table TABLE_NAME purge;

if you have already droped the tables without using purge in drop command, the you can use the following command

SQL> purge table TABLE_NAME ;

Free up storage, Oracle 10g

SQL> alter table TABLE_NAME deallocate unused;

In order to check the impace of these commands, you should check your free space before and after the use of purge. You will see the clear difference.

Empty the recycle bin, Oracle 10g

SQL> purge user_recyclebin;

source : internet



Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: