当前位置:网站首页>5. Oracle tablespace
5. Oracle tablespace
2022-07-05 06:22:00 【Cold leaves elegant_】
- Create a table space that is automatically partitioned under local management USERTBS1, The corresponding data file is 20m
create tablespace usertbs1 datafile 'D:\app\Snakewood\oradata\orcl\usertbs1.dbf' size 20m;
- Create a table space under local management mode USERTBS2, The size of each partition is 512K
create tablespace usertbs2 datafile 'D:\app\Snakewood\oradata\mydba\usertbs2.dbf' size 20m extent management local uniform size 512k;
- modify USERTBS1 Table space size , Change the data file of the table space to automatic expansion , Maximum 100M
alter database datafile 'D:\app\Snakewood\oradata\mydba\usertbs1.dbf' autoextend on next 5m maxsize 100m;
- by USERTBS2 Add a data file to the table space , size 20M
alter tablespace usertbs2 add datafile 'D:\app\Snakewood\oradata\mydba\usertbs2_1.dbf' size 20m;
- Create a temporary table space TEMPTBS1, And set it as the default temporary table space of the database
create temporary tablespace temptbs1 tempfile 'D:\app\Snakewood\oradata\mydba\ temptbs1_1.dbf' size 20m extent management local uniform size 16m;
alter database default temporary tablespace temptbs1;
- Use SQL Command to USERTBS1 Tablespaces perform online and offline state transitions
Alter tablespace USERTBS1 offline;
Alter tablespace USERTBS1 online;
- Create a SC surface (SNO,CNO,GRADE), increase tablespace users Words and expressions , And then USERS The tablespace is set to read-only , Try to SC Add a record to the table
create table SC (
SNO varchar2(20) primary key,
CNO varchar2(20) not null,
GRADE number(3) not null
)
tablespace users;
alter tablespace users read only;
insert into SC values (‘B201801’,’C0101’,98);
- Create a rollback table space UNDOTBS2, And as the undo tablespace of the database
create undo tablespace UNDOTBS2 datafile ‘D:\app\Snakewood\oradata\mydba\ UNDOTBS2_1.DBF’ size 20m;
- take USERTBS1 Tablespace renamed to USERTBS01
alter tablespace USERTBS1 rename to USERTBS01;
- Delete tablespace USERTBS2, Delete the contents and data files of the table space at the same time
drop tablespace USERTBS2 including contents and datafiles;
边栏推荐
- Regulations for network security events of vocational group in 2022 Guizhou Vocational College skill competition
- [rust notes] 13 iterator (Part 2)
- LeetCode 0108. Convert an ordered array into a binary search tree - the median of the array is the root, and the left and right of the median are the left and right subtrees respectively
- LeetCode-54
- Chapter 6 relational database theory
- 求组合数 AcWing 887. 求组合数 III
- __ builtin_ Popcount() counts the number of 1s, which are commonly used in bit operations
- 927. Trisection simulation
- 4.Oracle-重做日志文件管理
- [wustctf2020] plain_ WP
猜你喜欢
Doing SQL performance optimization is really eye-catching
Suppose a bank's ATM machine, which allows users to deposit and withdraw money. Now there is 200 yuan in an account, and both user a and user B have the right to deposit and withdraw money from this a
1.15 - input and output system
Alibaba established the enterprise digital intelligence service company "Lingyang" to focus on enterprise digital growth
Day 2 document
Introduction to LVS [unfinished (semi-finished products)]
【LeetCode】Easy | 20. Valid parentheses
[2021]IBRNet: Learning Multi-View Image-Based Rendering Qianqian
Bash exercise 17 writing scripts to install the server side of FRP reverse proxy software
容斥原理 AcWing 890. 能被整除的数
随机推荐
Groupbykey() and reducebykey() and combinebykey() in spark
容斥原理 AcWing 890. 能被整除的数
MySQL advanced part 2: SQL optimization
Bash exercise 17 writing scripts to install the server side of FRP reverse proxy software
LeetCode-54
Simple selection sort of selection sort
区间问题 AcWing 906. 区间分组
4. 对象映射 - Mapping.Mapster
MPLS experiment
Leetcode heap correlation
Error ora-28547 or ora-03135 when Navicat connects to Oracle Database
AE tutorial - path growth animation
LeetCode 0108. Convert an ordered array into a binary search tree - the median of the array is the root, and the left and right of the median are the left and right subtrees respectively
Multi screen computer screenshots will cut off multiple screens, not only the current screen
3.Oracle-控制文件的管理
[rust notes] 14 set (Part 1)
Liunx starts redis
Leetcode-1200: minimum absolute difference
快速使用Amazon MemoryDB并构建你专属的Redis内存数据库
Open source storage is so popular, why do we insist on self-development?