Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Attach a database in Oracle 10g

Re: Attach a database in Oracle 10g

From: Howard J. Rogers <hjr_at_dizwell.com>
Date: Wed, 08 Dec 2004 12:48:38 +1100
Message-ID: <41b65d75$0$30622$afc38c87@news.optusnet.com.au>


Greg Doherty wrote:
> Hi,
>
> I have been sent a copy of a database and would like to be able to access
> it. I copied it to a subdirectory under the oradata directory. I'm using
> WinXP and Oracle 10g. How do I go about attaching to this database? I can
> use the Database Configuration Assistant to create a new database, but I
> can't find a way to attach to an existing one.
>
> Thanks,
> - Greg
>
>

A bit more detail would be nice. What exactly is in the database that you've been given? All data files? All online redo logs? All control files? The spfile and/or the init.ora?

If yes to all of the above, and if the original database was copied when it was cold, and after it had been shutdown cleanly, then you should be able to....

  1. Use oradim at the command line to create the service needed to support the instance you're going to create.

oradim -new -sid XXX -pfile c:\wherever\your\init.ora\or\spfile\is

2. set ORACLE_SID=XXX

3. Sqlplus "/ as sysdba"

But it could get a lot more complicated than that.

Regards
HJR Received on Tue Dec 07 2004 - 19:48:38 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US