Thread: DBlink, postgres to DB2

DBlink, postgres to DB2

From
Postgres India
Date:
Hi, 
I am trying to connect DB2 from postgres using dblink, is there any configuration required at DB2 and postgres server.

If any command string please provide it.



Thanks
Manmohan. K

Re: DBlink, postgres to DB2

From
Rémi Cura
Date:
Seems dblink is for postgres to postgres connections.
Cheers,
Rémi-C

2014-10-22 12:45 GMT+02:00 Postgres India <pgbugindia@gmail.com>:
Hi, 
I am trying to connect DB2 from postgres using dblink, is there any configuration required at DB2 and postgres server.

If any command string please provide it.



Thanks
Manmohan. K


Re: DBlink, postgres to DB2

From
Rémi Cura
Date:
You may want to use foreign data wrapper (fdw)

https://wiki.postgresql.org/wiki/Foreign_data_wrappers

Cheers,
Rémi-C

2014-10-22 12:50 GMT+02:00 Rémi Cura <remi.cura@gmail.com>:
Seems dblink is for postgres to postgres connections.
Cheers,
Rémi-C

2014-10-22 12:45 GMT+02:00 Postgres India <pgbugindia@gmail.com>:
Hi, 
I am trying to connect DB2 from postgres using dblink, is there any configuration required at DB2 and postgres server.

If any command string please provide it.



Thanks
Manmohan. K



Re: DBlink, postgres to DB2

From
Pavel Stehule
Date:
Hi

try to use a Perl implementation https://github.com/davidfetter/DBI-Link

There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod

Or you can use a mentioned fdw wrapper - there is ODBC wrapper https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can access DB2 via generic ODBC DB2 driver

Regards

Pavel



2014-10-22 12:45 GMT+02:00 Postgres India <pgbugindia@gmail.com>:
Hi, 
I am trying to connect DB2 from postgres using dblink, is there any configuration required at DB2 and postgres server.

If any command string please provide it.



Thanks
Manmohan. K


Re: DBlink, postgres to DB2

From
Merlin Moncure
Date:
On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> Hi
>
> try to use a Perl implementation https://github.com/davidfetter/DBI-Link
>
> There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod
>
> Or you can use a mentioned fdw wrapper - there is ODBC wrapper
> https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can
> access DB2 via generic ODBC DB2 driver

jdbc-fdw should work too.

https://github.com/atris/JDBC_FDW

merlin


Re: DBlink, postgres to DB2

From
Postgres India
Date:
Thanks a lot Remi, Merlin and Pavel...........I will give it a try.

On Wed, Oct 22, 2014 at 6:36 AM, Merlin Moncure <mmoncure@gmail.com> wrote:
On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> Hi
>
> try to use a Perl implementation https://github.com/davidfetter/DBI-Link
>
> There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod
>
> Or you can use a mentioned fdw wrapper - there is ODBC wrapper
> https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can
> access DB2 via generic ODBC DB2 driver

jdbc-fdw should work too.

https://github.com/atris/JDBC_FDW

merlin

Re[2]: [GENERAL] DBlink, postgres to DB2

From
Миша Тюрин
Date:

http://multicorn.org/
another cool stuff to generalize interconnections


Wed, 22 Oct 2014 22:34:06 -0700 от Postgres India <pgbugindia@gmail.com>:
Thanks a lot Remi, Merlin and Pavel...........I will give it a try.

On Wed, Oct 22, 2014 at 6:36 AM, Merlin Moncure <mmoncure@gmail.com> wrote:
On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> Hi
>
> try to use a Perl implementation https://github.com/davidfetter/DBI-Link
>
> There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod
>
> Or you can use a mentioned fdw wrapper - there is ODBC wrapper
> https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can
> access DB2 via generic ODBC DB2 driver

jdbc-fdw should work too.

https://github.com/atris/JDBC_FDW

merlin





Re: DBlink, postgres to DB2

From
Postgres India
Date:
Hi ,

While i try to install psqlDDBC, i get this error , i have SUSE Linux Enterprise Server 11 , trying to find a solution still have no idea.

./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking -Wall is a valid compile option... yes
checking for odbc_config... no
configure: error: odbc_config not found (required for unixODBC build)


Regards
Manmohan. K


On Thu, Oct 23, 2014 at 2:41 PM, Миша Тюрин <tmihail@bk.ru> wrote:

http://multicorn.org/
another cool stuff to generalize interconnections


Wed, 22 Oct 2014 22:34:06 -0700 от Postgres India <pgbugindia@gmail.com>:

Thanks a lot Remi, Merlin and Pavel...........I will give it a try.

On Wed, Oct 22, 2014 at 6:36 AM, Merlin Moncure <mmoncure@gmail.com> wrote:
On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> Hi
>
> try to use a Perl implementation https://github.com/davidfetter/DBI-Link
>
> There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod
>
> Or you can use a mentioned fdw wrapper - there is ODBC wrapper
> https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can
> access DB2 via generic ODBC DB2 driver

jdbc-fdw should work too.

https://github.com/atris/JDBC_FDW

merlin





Re: DBlink, postgres to DB2

From
Pavel Stehule
Date:


2014-10-30 8:47 GMT+01:00 Postgres India <pgbugindia@gmail.com>:
Hi ,

While i try to install psqlDDBC, i get this error , i have SUSE Linux Enterprise Server 11 , trying to find a solution still have no idea.

./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking -Wall is a valid compile option... yes
checking for odbc_config... no
configure: error: odbc_config not found (required for unixODBC build)


Regards

Pavel

 

Regards
Manmohan. K


On Thu, Oct 23, 2014 at 2:41 PM, Миша Тюрин <tmihail@bk.ru> wrote:

http://multicorn.org/
another cool stuff to generalize interconnections


Wed, 22 Oct 2014 22:34:06 -0700 от Postgres India <pgbugindia@gmail.com>:

Thanks a lot Remi, Merlin and Pavel...........I will give it a try.

On Wed, Oct 22, 2014 at 6:36 AM, Merlin Moncure <mmoncure@gmail.com> wrote:
On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> Hi
>
> try to use a Perl implementation https://github.com/davidfetter/DBI-Link
>
> There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod
>
> Or you can use a mentioned fdw wrapper - there is ODBC wrapper
> https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can
> access DB2 via generic ODBC DB2 driver

jdbc-fdw should work too.

https://github.com/atris/JDBC_FDW

merlin






Re: DBlink, postgres to DB2

From
Devrim Gündüz
Date:
Hi,

On Thu, 2014-10-30 at 00:47 -0700, Postgres India wrote:
> configure: error: odbc_config not found (required for unixODBC build)

I think you need to install unixODBC-devel rpm via yast.

Regards,

--
Devrim GÜNDÜZ
Principal Systems Engineer @ EnterpriseDB: http://www.enterprisedb.com
PostgreSQL Danışmanı/Consultant, Red Hat Certified Engineer
Twitter: @DevrimGunduz , @DevrimGunduzTR


Attachment

Re: DBlink, postgres to DB2

From
Craig Ringer
Date:
On 10/22/2014 06:45 PM, Postgres India wrote:
> Hi,
> I am trying to connect DB2 from postgres using dblink, is there any
> configuration required at DB2 and postgres server.

You'll need dbi-link (which uses Perl's DBI drivers) or a foreign data
wrapper.

dblink is for connections between PostgreSQL servers.


--
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services