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.
Hey, I was trying to export the schema from my mysql instance and the ENUM data type is not getting exported properly. This is an issue with ora2pg built from commit hash: 24a4761fdd2d0e6f167807e3fba0576c5f0af491
Here is DDL of the original table:
CREATE TABLE `clothes` (
`product_id` int NOT NULL AUTO_INCREMENT,
`name` varchar(255) NOT NULL,
`fabric` text NOT NULL,
`size` enum('small','medium','large') NOT NULL,
PRIMARY KEY (`product_id`)
)
Exported table by using ora2pg built from commit hash: 24a4761fdd2d0e6f167807e3fba0576c5f0af491
CREATE TABLE clothes (
product_id bigserial,
name varchar(255) NOT NULL,
fabric text NOT NULL,
size , 6 NOT NULL,
PRIMARY KEY (product_id)
) ;
Exported table by using ora2pg built from 23.1 release (This is working fine):
CREATE TYPE clothes_size_t AS ENUM ('small','medium','large');
CREATE TABLE clothes (
product_id serial,
name varchar(255) NOT NULL,
fabric text NOT NULL,
size clothes_size_t NOT NULL,
PRIMARY KEY (product_id)
) ;
Hey, I was trying to export the schema from my mysql instance and the ENUM data type is not getting exported properly. This is an issue with ora2pg built from commit hash: 24a4761fdd2d0e6f167807e3fba0576c5f0af491
Here is DDL of the original table:
Exported table by using ora2pg built from commit hash: 24a4761fdd2d0e6f167807e3fba0576c5f0af491
Exported table by using ora2pg built from 23.1 release (This is working fine):
cc: @darold