Solved

How to Import a complete Database in Oracle 9i

Posted on 2014-10-18
2
428 Views
Last Modified: 2014-10-19
I export a backup of my database using the following. How can I overwrite the existing database from a dump file.

set oracle_sid=scrp
exp scrapware/recycle grants=yes owner=scrapware

file=H:\scrp-dump\expSCRp%date:~4,2%%date:~7,2%%date:~-4%%time:~0,2%%time:~3,2%%

time:~6,2%%time:~-2%.dmp
0
Comment
Question by:Vincent Costanza
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 23

Assisted Solution

by:David
David earned 150 total points
ID: 40389610
0
 
LVL 77

Accepted Solution

by:
slightwv (䄆 Netminder) earned 350 total points
ID: 40391004
>>How can I overwrite the existing database from a dump file.

In Oracle a database refers to the files on disk.
An Instance is the memory and server processes.
A Schema is pretty much a user that owns objects.

Based on the question asked:
I assume you exported a schema from one database and want to overwrite that schema in a different database.

If so:
You shouldn't need fromuser and touser if you want to import it into the same schema in a different database.

Binary copy the file from serverA to serverB.  This isn't necessary because the classic exp/imp utilities can run from the client side but it makes things simpler if the file is on the database server.

In the other database, drop and recreate the user then:
imp scrapware/recycle full=Y
file=H:\scrp-dump\expSCRp%date:~4,2%%date:~7,2%%date:~-4%%time:~0,2%%time:~3,2%%
time:~6,2%%time:~-2%.dmp

If you want to do something different, please let us know what it is.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How to Create User-Defined Aggregates in Oracle Before we begin creating these things, what are user-defined aggregates?  They are a feature introduced in Oracle 9i that allows a developer to create his or her own functions like "SUM", "AVG", and…
Cursors in Oracle: A cursor is used to process individual rows returned by database system for a query. In oracle every SQL statement executed by the oracle server has a private area. This area contains information about the SQL statement and the…
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question