Reputation: 115
I created database in oracle 11g this database name are "test". and then i created new user in test database. i connect to created new user and password and then create table, procedure and triggers in SQL Developer. i will backup this test database and restore in another pc. please help me step by step how to backup and restore.
Upvotes: 10
Views: 77659
Reputation: 27251
To transfer your user(schema) with all related objects(table, triggers and so on) to another computer with Oracle 11g installed on, you can do the following:
On a first computer (where you have your user created) use exp command line utility to unload user's(schema's) data to an OS file(dump file).
exp userid=yourusername/youruserpassword@Connect_Identifier File=OSPath
Example
Exp userid=scott/tiger@ORCL file=c:\scott.dmp
transfer created *.dmp file to another computer with Oracle 11 installed on and use imp command line utility to load *.dmp file into a NEW (it means you have to create a user id it doesn't exist already ) created schema(users)
imp userid/password@Connect_identifier fromuser=user_name_you_have_data_unloaded_from touser=new_user_name file=Path_to_*.dmp file
As you are using Oracle 11g you can use Data pump Export and Data Pump Import utilities to do the same thing. Exp and Imp are there for backward compatibility but the will work as expected.
Upvotes: 16