Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VvMu5-0005UX-AN for pgsql-odbc@arkaria.postgresql.org; Tue, 24 Dec 2013 07:59:49 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1VvMu4-0003ld-O8 for pgsql-odbc@arkaria.postgresql.org; Tue, 24 Dec 2013 07:59:48 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VvMu3-0003ki-Vx for pgsql-odbc@postgresql.org; Tue, 24 Dec 2013 07:59:48 +0000 Received: from dub0-omc4-s20.dub0.hotmail.com ([157.55.2.95]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VvMu0-0008Hd-Ov for pgsql-odbc@postgresql.org; Tue, 24 Dec 2013 07:59:47 +0000 Received: from DUB117-W51 ([157.55.2.71]) by dub0-omc4-s20.dub0.hotmail.com with Microsoft SMTPSVC(6.0.3790.4675); Mon, 23 Dec 2013 23:59:43 -0800 X-TMN: [HARxbTHxVIBe9WX8edb2dOTavKewrYWr] X-Originating-Email: [bart_klein_ikink@hotmail.com] Message-ID: Content-Type: multipart/alternative; boundary="_689d4e81-81e3-4432-88fe-7226b32734cc_" From: Bart Klein Ikink To: "pgsql-odbc@postgresql.org" Subject: Database link from Postgres to Oracle using ODBC Date: Tue, 24 Dec 2013 07:59:43 +0000 Importance: Normal MIME-Version: 1.0 X-OriginalArrivalTime: 24 Dec 2013 07:59:43.0363 (UTC) FILETIME=[1ADD6530:01CF007E] X-Pg-Spam-Score: 0.3 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-odbc Precedence: bulk Sender: pgsql-odbc-owner@postgresql.org --_689d4e81-81e3-4432-88fe-7226b32734cc_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable I am a newbie so I may have done something wrong. I have made a database li= nk from Oracle 11.2 to Postgres 9.2 using unixODBC=2C Oracle HS and psqlODB= C. It is working fine. =20 Now I want to do it the other way around=2C which is making a database link= from Postgres 9.2 to Oracle 11.2. I have figured out that I have to instal= l ODBC-Link 1.0.4 or Oracle_fdw 0.9.9. =20 I tried to install ODBC-Link 1.0.4 and Oracle_fdw 0.9.9=2C but both have si= milar problems as shown below (using ODBC-Link 1.0.4): =20 [root]# export PATH=3D$PATH:/usr/pgsql-9.2/bin [root]# pg_config --pgxs /usr/pgsql-9.2/lib/pgxs/src/makefiles/pgxs.mk [root]# USE_PGXS=3D1 make gcc -O2 -g -pipe -Wall -Wp=2C-D_FORTIFY_SOURCE=3D2 -fexceptions -fstack-pro= tector --param=3Dssp-buffer-size=3D4 -m64 -mtune=3Dgeneric -I/usr/include/e= t -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement = -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-ali= asing -fwrapv -fpic -I. -I. -I/usr/pgsql-9.2/include/server -I/usr/pgsql-9.= 2/include/internal -I/usr/include/et -D_GNU_SOURCE -I/usr/include/libxml2 = -I/usr/include -c -o odbclink.o odbclink.c In file included from odbclink.c:17: odbclink.h:4:17: error: sql.h: No such file or directory odbclink.h:5:20: error: sqlext.h: No such file or directory In file included from odbclink.c:17: odbclink.h:11: error: expected specifier-qualifier-list before =E2SQLHENV= =E2 odbclink.h:17: error: expected specifier-qualifier-list before =E2SQLHSTMT= =E2 odbclink.c: In function =E2_PG_fini=E2: odbclink.c:106: warning: implicit declaration of function =E2SQLDisconnect= =E2 odbclink.c:106: error: =E2odbcconn=E2 has no member named =E2hCon=E2 odbclink.c:107: warning: implicit declaration of function =E2SQLFreeConnect= =E2 odbclink.c:107: error: =E2odbcconn=E2 has no member named =E2hCon=E2 odbclink.c:108: warning: implicit declaration of function =E2SQLFreeEnv=E2 odbclink.c:108: error: =E2odbcconn=E2 has no member named =E2hEnv=E2 .... many more lines =20 What is the problem here? = --_689d4e81-81e3-4432-88fe-7226b32734cc_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
I am a newbie so I may have done= something wrong. I have made a database link from Oracle 11.2 =3Bto Po= stgres 9.2 =3Busing unixODBC=2C Oracle HS =3Band psqlODBC. It is wo= rking fine.
 =3B
Now I want to do it the other way around=2C which is making a database link= from Postgres 9.2 to Oracle 11.2. I have figured out that I have to instal= l ODBC-Link 1.0.4 or Oracle_fdw 0.9.9.
 =3B
I tried to install ODBC-Link 1.0.4 =3Band Oracle_fdw 0.9.9=2C but both = have similar problems as shown below (using ODBC-Link 1.0.4):
 =3B
[root]# export PATH=3D$PATH:/usr/pgsql-9.2/bin
[root]# pg_config --pgxs
/usr/pgsql-9.2/lib/pgxs/src/makefiles/pgxs.mk[root]# USE_PGXS=3D1 make
gcc -O2 -g -pipe -Wall -Wp=2C-D_FORTIFY_SOUR= CE=3D2 -fexceptions -fstack-protector --param=3Dssp-buffer-size=3D4 -m64 -m= tune=3Dgeneric -I/usr/include/et -Wall -Wmissing-prototypes -Wpointer-arith= -Wdeclaration-after-statement -Wendif-labels -Wmissing-format-attribute -W= format-security -fno-strict-aliasing -fwrapv -fpic -I. -I. -I/usr/pgsql-9.2= /include/server -I/usr/pgsql-9.2/include/internal -I/usr/include/et -D_GNU_= SOURCE -I/usr/include/libxml2 =3B -I/usr/include =3B -c -o odbclink= .o odbclink.c
In file included from odbclink.c:17:
odbclink.h:4:17: e= rror: sql.h: No such file or directory
odbclink.h:5:20: error: sqlext.h:= No such file or directory
In file included from odbclink.c:17:
odbcl= ink.h:11: error: expected specifier-qualifier-list before =E2SQLHENV=E2
= odbclink.h:17: error: expected specifier-qualifier-list before =E2SQLHSTMT= =E2
odbclink.c: In function =E2_PG_fini=E2:
odbclink.c:106: warning: = implicit declaration of function =E2SQLDisconnect=E2
odbclink.c:106: err= or: =E2odbcconn=E2 has no member named =E2hCon=E2
odbclink.c:107: warnin= g: implicit declaration of function =E2SQLFreeConnect=E2
odbclink.c:107:= error: =E2odbcconn=E2 has no member named =E2hCon=E2
odbclink.c:108: wa= rning: implicit declaration of function =E2SQLFreeEnv=E2
odbclink.c:108:= error: =E2odbcconn=E2 has no member named =E2hEnv=E2
....
many more lines
 =3B
What is the problem here?
= --_689d4e81-81e3-4432-88fe-7226b32734cc_--