Beruflich Dokumente
Kultur Dokumente
/ro1ect /age2
'tt/2**oracle$fdw./ro1ects./ostgres3l.org*
.oreign -ata &ra//er conce/ts
PostgreSQL ob1ect
.oreign -ata &ra//er
.oreign Server
User +a//ing
.oreign 4able
corres/onds to
Oracle -5 software
Oracle instance
Oracle credentials
Oracle table*view
A sim/le e0am/le
pgdb=# CREATE EXTENSION oracle_fdw;
pgdb=# CREATE SERVER oradb FOREIGN DATA RA!!ER
oracle_fdw O!TIONS
"db#er$er&''db#er$er()*do)a+,(co)'ORAD-&.;
pgdb=# GRANT /SAGE ON FOREIGN SERVER oradb
TO pg0#er;
pgdb=# 1co,,ec2 pgdb pg0#er
pgdb=3 CREATE /SER 4A!!ING FOR pg0#er
SERVER oradb
O!TIONS "0#er &ora0#er&5 pa##word &orapwd&.;
pgdb=3 CREATE FOREIGN TA-6E people "
+d +,2eger NOT N/665
,a)e $arc7ar"89.5
b+r27da* da2e NOT N/66
. SERVER oradb O!TIONS "2able &!EO!6E&.;
-ata migration wit' oracle_fdw
-EGIN;
CREATE TA-6E loc_people AS
"SE6ECT : FRO4 people.;
A6TER TA-6E loc_people
ADD CONSTRAINT people_p;e*
!RI4AR< =E<"+d.;
DRO! FOREIGN TA-6E people;
A6TER TA-6E loc_people
RENA4E TO people;
CO44IT;
S/ecial .eatures of oracle_fdw
EX!6AIN su//ort
6ew in 7.!2
all written in 9
no intermediar) files