Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


Temporary Tablespace is Empty

Posted on 2013-06-21
Medium Priority
Last Modified: 2013-06-21
I'm getting an error.  I've researched it but still not sure what to do.

I run...

select dbms_metadata.get_ddl ('PACKAGE_BODY','<<package name>>') from dual

And I get...

ORA-25153: Temporary Tablespace is Empty
ORA-06512: at "SYS.DBMS_METADATA", line 5088
ORA-06512: at "SYS.DBMS_METADATA", line 7589
ORA-06512: at line 1
25153. 00000 -  "Temporary Tablespace is Empty"
*Cause:    An attempt was made to use space in a temporary tablespace with
           no files.
*Action:   Add files to the tablespace using ADD TEMPFILE command.
Question by:patriotpacer
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 39266093
Looks like you don't have a temporary tablespace or it is offline.

Possible the user you are using doesn't have a default temp tablepsace.

 select tablespace_name, status from dba_temp_files;

select temporary_tablespace from dba_users where username='SOME_USERNAME';

Author Comment

ID: 39266105
>> select tablespace_name, status from dba_temp_files;

Brings back nothing

>>select temporary_tablespace from dba_users where username='SOME_USERNAME';

I ran with my username and get the result back of "temp"

BTW - this is the crap I hate about Oracle.
LVL 77

Accepted Solution

slightwv (䄆 Netminder) earned 2000 total points
ID: 39266118
>>Brings back nothing

Then you need to create a temp tablespace:

Creating a Locally Managed Temporary Tablespace
Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  


Author Comment

ID: 39266143
Why am I getting this when I just run a query to see a package contents?
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 39266157
My guess is dbms_metadata creates temporary objects internally.

Some objects cannot be created in a permanent tablespace.

Author Comment

ID: 39266175
Thx, slightwv.

I'll accept your answer, but I can't test it.  Says I have ""insufficient privileges."

Never thought this would be so hard.
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 39266185
>> Says I have ""insufficient privileges."

You need to be SYS to create tablespaces.  If you don't have SYS access, have your DBA create it for you.

Any database created should have a TEMP tablespace.  Since yours doesn't, I would try my best to figure out why.  This can do bad things to your database...

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Truncate is a DDL Command where as Delete is a DML Command. Both will delete data from table, but what is the difference between these below statements truncate table <table_name> ?? delete from <table_name> ?? The first command cannot be …
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question