Ora2Pg
Configuration

Exporting LONG RAW

Configuration for exporting LONG RAW

Exporting LONG RAW

If you still have columns defined as LONG RAW, Ora2Pg will not be able to export these kinds of data. The OCI library fails to export them and always returns the same first record. To be able to export the data you need to transform the field as BLOB by creating a temporary table before migrating data. For example, the Oracle table:

SQL> DESC TEST_LONGRAW
 Name                 NULL ?   Type
 -------------------- -------- ----------------------------
 ID                            NUMBER
 C1                            LONG RAW

needs to be "translated" into a table using BLOB as follows:

CREATE TABLE test_blob (id NUMBER, c1 BLOB);

And then copy the data with the following INSERT query:

INSERT INTO test_blob SELECT id, to_lob(c1) FROM test_longraw;

Then you just have to exclude the original table from the export (see EXCLUDE directive) and to rename the new temporary table on the fly using the REPLACE_TABLES configuration directive.

On this page

Powered by HexaCluster

HexaRocket

Ora2Pg+ for Enterprises

Need enterprise-grade migration? Get zero-downtime & continuous data replication.

Explore HexaRocket