Expand the tablespace first, check the tablespace name and file selecttablespace_name, file_id, file_name, round (bytes (1024*1024), 0) partition; 1. Add the data file ALTERTABLESPACEgameADDDATAFILEoracleoradatadb
Expand the tablespace first, check the tablespace name and its file select tablespace_name, file_id, file_name, round (bytes/(1024*1024), 0) total_space from dba_data_files order by tablespace_name; 1. ADD the data file alter tablespace game add datafile '/oracle/oradata/db
Extended tablespace
First, check the name and file of the tablespace.
Select tablespace_name, file_id, file_name,
Round (bytes/(1024*1024), 0) total_space
From dba_data_files
Order by tablespace_name;
1. Add data files
Alter tablespace game
Add datafile '/oracle/oradata/db/game02.dbf' SIZE 1000 M;
2. manually add data file size
Alter database datafile '/oracle/oradata/db/GAME. dbf'
RESIZE 4000 M;
3. Set automatic expansion of data files
Alter database datafile '/oracle/oradata/db/GAME. dbf
Autoextend on next 100 M
MAXSIZE 10000 M;
View tablespace information after setting
Select a. TABLESPACE_NAME, A. bytes total, B. BYTES USED, C. BYTES FREE,
(B. BYTES * 100)/A. BYTES "% USED", (C. BYTES * 100)/A. BYTES "% FREE"
From sys. SM $ TS_AVAIL A, SYS. SM $ TS_USED B, SYS. SM $ TS_FREE C
Where a. TABLESPACE_NAME = B. TABLESPACE_NAME AND A. TABLESPACE_NAME = C. TABLESPACE_NAME;
JSP Blog
Expand the tablespace first, check the tablespace name and its file select tablespace_name, file_id, file_name, round (bytes/(1024*1024), 0) total_spacefrom dba_data_filesorder by tablespace_name; 1. add the data file alter tablespace gameADD DATAFILE '/oracle/oradata/db/GAME02.dbf 'size 1000 M; 2. manually add the data file size alter database datafile '/oracle/oradata/db/GAME. dbf'resize 4000 M; 3. set the data file to automatically expand alter database datafile '/oracle/oradata/db/GAME. dbfAUTOEXTEND on next 100 MMAXSIZE 10000 M; check the tablespace information after setting select. TABLESPACE_NAME,. bytes total, B. bytes used, C. bytes free, (B. BYTES * 100)/. BYTES "% USED", (C. BYTES * 100)/. BYTES "% FREE" from sys. SM $ TS_AVAIL A, SYS. SM $ TS_USED B, SYS. SM $ TS_FREE cwhere. TABLESPACE_NAME = B. TABLESPACE_NAME and. TABLESPACE_NAME = C. TABLESPACE_NAME;