1. Installing strawberry-perl-5.24
2. Installing ora2pg-17.4
#perl makefile.pl
#dmake && Dmake Install
3. Installing ORA2PG related Moudel
#安装方式同ora2pg
#DBD-oracle-1.74
#DBD-pg-3.5.3
#DBI-1.636
4. Configuring the Ora2pg_dist.conf directory: C:\ORA2PG
oracle_home d:\db\ora11gr2\product\11.2 . 0 \dbhome_1oracle_dsn dbi:Oracle:host =127.0 . 0.1 ; Sid=orcloracle_user System # --< Span style= "color: #000000;" > user name Oracle_pwd askoracle # -- password user_grants 1 schema SCOTT #导出SCOTT用户下的对象TYPE TABLE data# exported objects such as view, tablespace, etc., refer to Readmeallow EMP #SCOTT用户下的EMP表DATA_LIMIT 1000000 =postgres;host=127.0 . 0.1 ;p ort=5432 pg_user postgres #用户名PG_PWD postgres #密码
5. Execute command line c:\>ora2pg-c C:\ora2pg\ora2pg_dist.conf
Note: When the command is complete, use the Build Table statement (generated under command execution directory, default output.sql) to establish the related table in PostgreSQL, and some field types need to be changed according to subsequent data insert operations
Once the table has been built, execute the command again and the data can be imported into the PostgreSQL database.
//
Text editing:
\ (\d{1,4}\) matches 1 to 4 digits in parentheses
Reference URL:
http://search.cpan.org/
Http://www.askoracle.org/oracle/backup/1009.html
ORA2PG Data Migration