I have installed oracle_fdw successfully. After I create extension oracle_fdw and
foreign table it shows the following error. Is this a server configuration problem?
--env
Oracle : 10.2.0.1
PostgreSQL: 9.1.3
--create foreign server
skytf=# CREATE SERVER oracle_srv
skytf-# FOREIGN DATA WRAPPER oracle_fdw
skytf-# OPTIONS (dbserver '//192.168.1.30:1521/MANUA');
CREATE SERVER
skytf=# grant usage on foreign server oracle_srv to skytf;
GRANT
--create mapping user
skytf=# CREATE USER MAPPING FOR skytf
skytf-# SERVER oracle_srv
skytf-# OPTIONS (user 'read_only', password 'read_only');
CREATE USER MAPPING
--create foreign table
skytf=# CREATE FOREIGN TABLE ft_test_1 (
skytf(# id integer,
skytf(# name character varying(20)
skytf(# ) SERVER oracle_srv
skytf-# OPTIONS (schema 'ocp', table 'test_1');
CREATE FOREIGN TABLE
skytf=# \c skytf skytf
skytf=> select * from ft_test_1;
ERROR: error connecting to Oracle: OCIEnvCreate failed to create environment handle
DETAIL: