Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: select data from different database
thanks...
sybrandb wrote:
> On Nov 24, 10:24 am, "skyloon" <skyl..._at_gmail.com> wrote:
> > hi,
> > may I know how to select data from different database?
> >
> > for example,
> > I've 2 databases, OracleDB and OracleAR
> > Connect with OracleAR in SQL*Plus
> >
> > select * from OracleDB.TableName
> >
> > does Oracle support this kind of query?
> >
> > how can I retrieve data from other database while im connecting with
> > other database?
>
>
> Oracle calls this distributed database. This is a separate manual in
> the documentation.
> To allow such a query, you must set up a database link to the remote
> database.
> This is done using the CREATE [PUBLIC] database link command
> create database link foo connect to <username>/<password> using '<tns
> service name for the remote db>'. username/password is for a remote
> user. If you leave this out while creating the link Oracle will connect
> using the current user and password.
> Further info in the docs.
>
> --
> Sybrand Bakker
> Senior Oracle DBA
Received on Fri Nov 24 2006 - 20:35:32 CST