darold / ora2pg

Ora2Pg is a free tool used to migrate an Oracle database to a PostgreSQL compatible schema. It connects your Oracle database, scan it automatically and extracts its structure or data, it then generates SQL scripts that you can load into PostgreSQL.
http://www.ora2pg.com/
GNU General Public License v3.0
991 stars 342 forks source link

Fix for Issue #1612 #1619

Closed simonpane closed 1 year ago

simonpane commented 1 year ago

Fix for Issue #1612 by making the Oracle schema and table name quoted identifiers in the SELECT COUNT(*) ... statement.

Note: this means that the lower-case comparison of the PostgreSQL and Oracle object names will not match exactly in line 17026 of subroutine set_pg_relation_name:

        $orig = " (origin: $table)" if (lc($cmptb) ne lc($table));

And the resulting output will show something similar to:

ORACLEDB:"MY_SCHEMA"."my_table":13
POSTGRES:my_table (origin: "MY_SCHEMA"."my_table"):13

Which is probably fine as it shows the object names with quoted accuracy. However, if not desirable, this the comparison of lc($table) in line 17026 could be modified to strip the double quotes.