--Create a data fileCreateTablespace--Create a table space and create a data file at the same timeCreate TemporaryTablespace--Create a temporary data file while creating a temporary table spaceAlterTablespace ...AddDataFile--to add a data file to a table spaceAlterTablespace ...AddTempfile--to add a data file to a temporary table spaceCreate Database --Create a data file when creating a databaseAlter Database...CreateDatefile--data felt restore operation, create a new data file to replace the failed data file--ExampleAlterTablespace usersAddDataFile'd:\app\administrator\oradata\orcl\users02.dbf'size 10m;--Modify data File sizeSelect file_name, autoextensible fromDba_data_files;--View how all data files in the current database are expanded. --ExampleAlter DatabaseDataFile'd:\app\administrator\oradata\orcl\users04.dbf'Size 10m autoextend on Next512k maxsize 100m;--change the availability of data files--to take an offline backup of a data file, you need to take the data file offline first. --When you need to rename a data file or change the location of a data file, you need to take the data file offline first. --If an error occurs when Oracle writes to a data file, the data file is automatically set to an offline state and recorded in an alert file. After troubleshooting, you need to manually re-restore the data file to an online state. --data files are missing or corrupted, you need to take the data files offline before starting the database. --In the archive mode:Alter DatabaseDatafile...online|Offline--set up offline and online persistent data files. Alter DatabaseTempfile...online|Offline--sets the temporary data file offline and online. --set the ORCL database to archive mode. shutdownImmediate--database has been closed, has been unloaded database, example Cheng closedStartup Mount--Example Cheng start--ExampleAlter Databasedatafile'd:\app\administrator\oradata\orcl\users01.dbf'Offline--OfflineRecover DataFile'd:\app\administrator\oradata\orcl\users01.dbf';--Complete Media recovery. Alter Databasedatafile'd:\app\administrator\oradata\orcl\users01.dbf'Online--Online
Oracle (Create data file)