oracle table space problem handling a maximum sentence grow automatically create a table space file

Space out lookup table, path name, size, whether to automatically increase the maximum size, increase the size of the next:
SELECT a.tablespace_name, a.FILE_NAME, bytes / 1024/1024 || 'M' "size", a.AUTOEXTENSIBLE, A .MAXBYTES, a.INCREMENT_BY from dba_data_files a order by a.FILE_NAME;

File size automatically open table space growth:
'' a statement on the query to the table space file name "+ ORADATA / orcl / datafile / .dbf 'alter database datafile autoextend on;

Open file table space size is automatically set to the maximum growth and maximum
alter database datafile 'on + ORADATA / orcl / datafile / queries to a table space file name .dbf' autoextend on maxsize unlimited;

Table space and open new file automatically increase the maximum is the largest:
Query first statement to alter tablespace tablespace add datafile '+ ORADATA / orcl / datafile / tablespace name a new file name .dbf' SIZE 10240M AUTOEXTEND ON NEXT 500M;

Query table space utilization:
the SELECT the UPPER (F.TABLESPACE_NAME) the AS "tablespace name",
the ROUND (D.AVAILB_BYTES, 2) the AS "table space (G)",
the ROUND (D.MAX_BYTES, 2) the AS "Final table space (G) ",
the ROUND ((D.AVAILB_BYTES - F.USED_BYTES), 2) the AS" used space (G) ",
the TO_CHAR (the ROUND ((D.AVAILB_BYTES - F.USED_BYTES) / D.AVAILB_BYTES 100,
2), '999.99') AS " use than",
the ROUND (F.USED_BYTES,. 6) the AS "free space (G)",
F.MAX_BYTES the AS "maximum block (M)"
the FROM (
the SELECT TABLESPACE_NAME,
the ROUND (the SUM ( BYTES) / (1024
1024 1024),. 6) USED_BYTES,
the ROUND (MAX (BYTES) / (1024
1024 1024),. 6) MAX_BYTES
the FROM SYS.DBA_FREE_SPACE
the GROUP BY TABLESPACE_NAME) F.,
(the SELECT DD.TABLESPACE_NAME,
ROUND(SUM(DD.BYTES) / (1024
1024 1024), 6) AVAILB_BYTES,
ROUND(SUM(DECODE(DD.MAXBYTES, 0, DD.BYTES, DD.MAXBYTES))/(1024
1024*1024),6) MAX_BYTES
FROM SYS.DBA_DATA_FILES DD
GROUP BY DD.TABLESPACE_NAME) D
WHERE D.TABLESPACE_NAME = F.TABLESPACE_NAME
ORDER BY 4 DESC;

Guess you like

Origin blog.51cto.com/mflag/2423763