---
title: "ORA-25153: Temporary Tablespace is Empty"
author: "edwards0307"
date: "2011-11-29T17:22:21Z"
tags: []
categories: ["数据库"]
slug: "ora-25153-temporary-tablespace-is-empty"
draft: false
lastmod: "2011-11-29T17:22:21Z"
id: 1284204
url: "https://killdbs.iteye.com/blog/1284204"
---

Today, I learned Temporary Table, I encountered for  ORA-25153: Temporary Tablespace is Empty

 

Following Step:

 

   1.create global temporary table tt(id number,name varchar2(10));

 

   2.insert into tt values(1,'lsh');

 

   ORA-25153: Temporary Tablespace is Empty

 

   3.I check the temp tablespace of the current user,find there are no  tempfiles

 

      select username,default\_tablespace,temporary\_tablespace from dba\_users  
       where username='HR';

 

       USERNAME   DEFAULT\_TABLESPACE  TEMPORARY\_TABLESPACE  
\--------------------------------------------------------------------------------------  
        HR                        USERS                    TEMP

        

        select file\_name,tablespace\_name from dba\_temp\_files;

        no rows

 

   4.alter tablespace temp add temp file '/u01/oradata/lsh/temp02.dbf' size 100m;

  

   5.select file\_name,tablespace\_name from dba\_temp\_files;

 

     FILE\_NAME            TABLESPACE\_NAME  
     ----------------------------  
     /u01/oradata/lsh/temp02.dbf  TEMP

   6.insert into tt values(1,'lsh');

   7.select * from tt;