zoukankan      html  css  js  c++  java
  • oracle一些对表的操作命令


    查询所有表空间信息

    select * from dba_tablespaces;

    查询是否自动扩展 (包括查询数据文件和临时文件)
    select tablespace_name,file_name,autoextensible from dba_data_files;
    select tablespace_name,file_name,autoextensible from dba_temp_files;

    修改临时表.dbf文件大小

    alter database tempfile 'C:appxroradataorclTEMP01.DBF' resize 300M;

    关闭/打开自动扩展

    alter database datafile '/oracle9i/data/temp01.dbf' autoextend off/on;(数据文件)
    alter database tempfile '/oracle9i/data/temp01.dbf' autoextend off/on;(临时文件)

    设置自动扩展表空间文件的扩展步长

    ALTER DATABASE DATAFILE 'SDE.SDE_LOGFILE_DATA_IDX1'  autoextend on next 10M;(数据文件)

    ALTER DATABASE TEMPFILE 'SDE.SDE_LOGFILE_DATA_IDX1'  autoextend on next 10M;(临时文件)

    当前用户下是否有某个表

    select count(*) from user_tables where table_name = '表名';0表示没有1表示有

    某个用户下是否有某个表

    select count(*) from dba_tables where owner = '用户名' and table_name = '表名';

  • 相关阅读:
    NOIP前做题记录
    AtCoder Grand Contest 021题解
    AtCoder Grand Contest 020 题解
    CODE FESTIVAL 2017 Final题解
    Code Chef October Challenge 2019题解
    5.20 校内模拟
    5.19 湖南师大附中省选模拟1
    NOI2016 循环之美
    博弈复习
    5.18 省选模拟
  • 原文地址:https://www.cnblogs.com/lettet/p/4330338.html
Copyright © 2011-2022 走看看