Abhiram Kulkarni
Abhiram Kulkarni

Reputation: 53

Cannot drop tablespace in oracle

HI,

problem 1

When i try to drop the tablespace using drop tablespace command, it fails and error message is the tablespace not exist.

when i do select * from dba_tablespaces, i can see the tablespace name.

Problem 2 when i try to connect the oracle using aquadata, i get "connection failed:- no more data to read from socket"

please suggest

Upvotes: 2

Views: 4924

Answers (1)

APC
APC

Reputation: 146229

"when i execute query select * from dba_tablespaces, the tablespace name is shown in lower case."

By default Oracle SQL is case insensitive. That is, both of these statements are equivalent:

drop tablespace TS1 including contents
/

drop tablespace ts1 including contents
/

However, when it comes to storing metadata Oracle uses UPPER CASE for object names. This doesn't matter unless when we created the database objects we wrapped their names in double-quotes. At that point Oracle becomes case sensitive.

It appears such is your situation. So you need to issue the command with the tablespace name in double quote:

drop tablespace "ts1" including contents
/

Upvotes: 8

Related Questions