ora2pg
ora2pg copied to clipboard
export_sequence should recognize create_schema config
When CREATE_SCHEMA
config is disabled, the sequence export still tries to create the schema, resulting in a permission failure if the Postgres user can't create the schema. This is an issue in environments where the person using Ora2Pg has rights to create tables etc. and insert data, but not create schemas (schema creation is done by a DBA, for example).
This should be an easy fix by changing lib/Ora2Pg.pm:5472 from:
if ($self->{export_schema} && ($self->{pg_schema} || $self->{schema})) {
to
if ($self->{export_schema} && $self->{create_schema} && ($self->{pg_schema} || $self->{schema})) {