Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VdpC1-0008F4-H5 for pgsql-admin@arkaria.postgresql.org; Tue, 05 Nov 2013 22:33:49 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1VdpC0-0003VF-S4 for pgsql-admin@arkaria.postgresql.org; Tue, 05 Nov 2013 22:33:48 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VdpBz-0003Tl-Ew for pgsql-admin@postgresql.org; Tue, 05 Nov 2013 22:33:47 +0000 Received: from plane.gmane.org ([80.91.229.3]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VdpBw-0005D8-20 for pgsql-admin@postgresql.org; Tue, 05 Nov 2013 22:33:46 +0000 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1VdpBr-0006AF-Ch for pgsql-admin@postgresql.org; Tue, 05 Nov 2013 23:33:39 +0100 Received: from p5081b712.dip0.t-ipconnect.de ([80.129.183.18]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 05 Nov 2013 23:33:39 +0100 Received: from chris by p5081b712.dip0.t-ipconnect.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 05 Nov 2013 23:33:39 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-admin@postgresql.org From: Christian Ullrich Subject: Re: Connecting to Oracle from Postgresql 9.2 on Windows Date: Tue, 05 Nov 2013 23:33:27 +0100 Lines: 51 Message-ID: <52797237.9050704@chrullrich.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@ger.gmane.org Cc: rgullstrom@gmail.com X-Gmane-NNTP-Posting-Host: p5081b712.dip0.t-ipconnect.de User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 In-Reply-To: X-Pg-Spam-Score: 0.8 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org * Albe Laurenz wrote: > It should work on 64-bit Windows, but I have no such machine to build it. > I'd be happy to publish binaries if somebody can build them. Every time I go up against what passes for a PostgreSQL build system on Windows, I am pleasantly surprised that it is not half as fragile as it looks. I now have working 64-bit builds of oracle_fdw.dll for both 9.2 and 9.3, built against the respective git branches. The only thing is, I'm not at all conversant with the build environment required for portable extension modules. I have been using Visual Studio 2012; do I have to build with 2008 to avoid runtime library clashes, or is that not an issue here? Rune, if you want to try my DLLs, I'll be happy to send them to you. postgres=# select version(); version ------------------------------------------------------------- PostgreSQL 9.3.1, compiled by Visual C++ build 1700, 64-bit (1 row) postgres=# create extension oracle_fdw; CREATE EXTENSION postgres=# create server oradb foreign data wrapper oracle_fdw options (dbserver '//oracle.local/orcl'); CREATE SERVER postgres=# create user mapping for postgres server oradb options (user 'hr', password 'hr'); CREATE USER MAPPING postgres=# create foreign table oradepts (department_id integer not null, department_name varchar(30) not null, manager_id integer, location_id integer) server oradb options (table 'DEPARTMENTS'); CREATE FOREIGN TABLE postgres=# select * from oradepts; department_id | department_name | manager_id | location_id ---------------+----------------------+------------+------------- 10 | Administration | 200 | 1700 20 | Marketing | 201 | 1800 30 | Purchasing | 114 | 1700 40 | Human Resources | 203 | 2400 50 | Shipping | 121 | 1500 60 | IT | 103 | 1400 ... -- Christian -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin