Oracle Database Operations (10)-logical backup and recovery of databases (tables), oracle backup and recovery
Logical backup and recovery of databases (tables)-export
System can export any scheme, for example:
Exp system/manager @ myoral owner (system, scott) file = d: system. dmp; // Note: two schemes can be exported: system scheme and Scott scheme.
Exp system/manager @ myoral owner (scott) file = d: system. dmp; // only the Scott scheme can be exported (this is to use the system to export the Scott scheme, the reason: the system permission is higher than Scott). When exporting the scheme, users with higher permissions are used to export the scheme.
Exp system/manager @ myoral owner (sys) file = d: system. dmp; // The sys scheme cannot be correctly exported at this time, because the system user permission is lower than the sys user
Database Export:(Export all solutions)
Exp userid = system/manager @ myoral full = y inctype = complete file = d: \ aa. dmp
(Perform operations in the bin folder of the installation directory ),
After the Export Statement is entered:
***1. Export the table
Logical backup and recovery of databases (tables)-Database Import
* ** 1. Import a table
(M123 is the password of Scott, myoral is the database instance, the table to be imported is emp, and its backup is emp. dmp)
***2. Import Solution
* ** 3. Import the database
Oracle database backup and recovery
A. instance is composed of ORACLE processes and memory used to connect to the database.
B. The design concepts of oracle and mysql and sqlserver are different. do not apply the mysql architecture to the oracle architecture.
C. A tablespace is a logical concept. A table is logically stored in a tablespace, but physically stored in a data file. A tablespace can have multiple data files. When creating a table, specify the tablespace. The actual data is written to the corresponding data file through the dbwr process.
D. Backup is divided into physical backup and logical backup. Physical backup is a backup data file, which can be a backup set or COPY, such as RMAN. Logical backup is the DDL, DCL, and DML operations of the backup, which is equivalent to mysqldump, tools such as EXP and EXPDP.
How to back up all data in a table in an oracle database
Export:
Exp username/password tables = table name file = System file Name
Import:
Imp username/password tables = table name file = System file Name
The above is a command line operation. If pl/SQL is better, select a path for export data and set a name. import data in the table to be imported, but the two tables must have the same structure.