Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 565
  • Last Modified:

tablespace

why I cannot drop tablespace...


SQL> select tablespace_name from dba_tablespaces;

TABLESPACE_NAME
------------------------------
SYSTEM
SYSAUX
UNDOTBS1
TEMP
USERS
EXAMPLE

6 rows selected.

SQL> drop tablespace example;
drop tablespace example
*
ERROR at line 1:
ORA-01549: tablespace not empty, use INCLUDING CONTENTS option


SQL> drop tablespace EXAMPLE;
drop tablespace EXAMPLE
*
ERROR at line 1:
ORA-01549: tablespace not empty, use INCLUDING CONTENTS option


SQL>
0
b7dba
Asked:
b7dba
  • 3
  • 2
1 Solution
 
slightwv (䄆 Netminder) Commented:
Error is self explainitory:
tablespace not empty, use INCLUDING CONTENTS option

drop tablespace EXAMPLE INCLUDING CONTENTS;

http://docs.oracle.com/cd/E11882_01/server.112/e26088/statements_9004.htm

also look into:  AND DATAFILES
0
 
expert9Commented:
use below query to confirm that there are objects in this tablespace

select segment_name from dba_segments where tablespace_name='EXAMPLE';

This will confirms that a table has been created in the tablespace EXAMPLE.

so it is essential to drop the tablespace and the contents in it so to fix this problem do the following:-

drop tablespace EXAMPLE including contents and datafiles;

This will fixed the issue.

The option INCLUDING CONTENTS AND DATAFILES will removes the physical files.
0
 
slightwv (䄆 Netminder) Commented:
expert9,

I see you are new to the site.  Welcome.  Please take some time to familiarize yourself with the site by reading through the Help section.

Please read through previous posts before posting so you do not post duplicate information.
0
 
expert9Commented:
0
 
expert9Commented:
well i believe there is alot of difference between in explaining things and duplicating things. client knows nothing thats what the expert exchange is about and experts have to provide solutions which can be understood by the client.......
any ways its ok zone advisor..
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now