各位高手:
我在oracle10g中创建了一个表空间,当我希望把它变成临时表空间时,在sqlplus中输入了 create tablespace XXXX temporary;命令,但系统提示 Operation not allowed on this tablespace 请问各位高手,为什么无法进行修改

解决方案 »

  1.   

    修改缺省temp表空间可以这样:create temporary tablespace temptest tempfile  '/dev/vgqrya01/rlv_08_temp_002';
    alter database default temporary tablespace temptest;
    drop tablespace temp;
    create temporary tablespace temp tempfile  '/dev/vgqrya01/rlv_08_temp_001';
    alter database default temporary tablespace temp;
    drop tablespace temptest;
      

  2.   

    1.运行:
    sqlplus /nolog;
    connect sys/oracle as sysdba;2.同时新创建temporary表空间:
    SQL> CREATE TEMPORARY TABLESPACE temp_1 TEMPFILE 'C:\ORACLE\ORADATA\temp_1.dbf' SIZE 5M AUTOEXTEND ON;3.更换临时表空间默认值:
    SQL> ALTER DATABASE DEFAULT  TEMPORARY TABLESPACE "temp_1";4.更新其他用户的临时表空间指向:
    1)用pl/sql developer 的sys用户登陆并运行sql window窗口:
    select 'alter user '||  username ||' temporary tablespace temp_1; ' from dba_users;
    2)用pl/sql developer 的sys用户登陆并运行command window窗口:
    将上面一步结果拷贝运行;5.删除系统的临时表空间temp:   
    SQL> drop tablespace temp  INCLUDING CONTENTS AND DATAFILES;