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: ******pl/sql*******

Re: ******pl/sql*******

From: dhruba <tapashc_at_my-deja.com>
Date: 2000/04/26
Message-ID: <8e7d8g$kt4$1@nnrp1.deja.com>#1/1

Hi ,

thanks very much for your reply,
pl look the scenario again.

I have oracle 8.1.5 server on NT4 with SP6 and DB2 4.3 database on os/390(Remote).
with oracle gateway 4.0.1.1.0

From the oracle server box I can connect to the DB2 database via SQLPLUS but being connect to oracle if I want to select from DB2 tables via sqlplus

connect scott/tiger; --- connect to oracle server(local) select * from db2table_at_abc.world, ---trying select from db2(remote) table using dblink

it gives error

ora-2085 Database link DB2L.world connects to G4XX.world ora-2063 Preceding line from abc.world

but I can connect like

sql> connect scott_at_abc.world
password ***********
connected
select * from db2table; it works fine!

dblink has already been created and is there in local oracle database.

any advice will be highly appreciated

rcy

In article <956267183.978494_at_newscache.cleveland.core.com>,   "Frank Bates" <fbates_at_stratos.net> wrote:
> To do this, you need the (extra $) Oracle product "Transparent
 Gateway for
> DB2" (TG4DB2) [http://technet.oracle.com/doc/gateways/tg4db2/toc.htm]
 which
> allows DB2 for OS/390 databases to be accessed as though they were
 Oracle
> tables. After installing the TG4DB2 software, you would need to
 configure
> it for the specific DB2 subsystem (and tables?). You probably need DB2
> Client Application Enabler that is available at
> http://www.software.ibm.com/data/db2/db2tech/clientpak.html.
>
> On your Oracle8i on NT server, you would then need to create a
 tnsnames.ora
> entry for the TG4DB2 server and a database link to the TG4DB2 server
> CREATE DATABASE LINK <linkname>
> CONNECT TO <tg4db2_user> IDENTIFIED BY <pwd>
> USING 'connect_string';
>
> Finally, you would do:
> INSERT
> INTO <localowner>.<localtable>
> [(<columnlist>)]
> (SELECT <columnlist>
> FROM <tg4db2_owner>.<tg4db2_table>@<linkname>
> WHERE <predicatelist>)
> ;
> dhruba <tapashc_at_my-deja.com> wrote in message
> news:8dlh2o$psb$1_at_nnrp1.deja.com...
> > Hi
> >
> > I have oracle 8.1.5 in NT4 server,
> > from sqlplus on this box I can connect to oracle and to another
> > db2 database(remote) which is on 0s/390,
> > I have 2 common table both on oracle and db2 database.
> >
> > I need to write a pl/sql which will select data from db2 table and
> > insert into oracle table.
> >
> > I am confused as when I am selecting data from db2 that is actually
> > not in this box but in a terminal like,
> >
> > How can I capture that db2(remote) data and put into oracle(local)
 table.
> >
> > please give some advice
> >
> > rcy
> >
> >
> > Sent via Deja.com http://www.deja.com/
> > Before you buy.
>
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Wed Apr 26 2000 - 00:00:00 CDT

Original text of this message

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