Hi,
I tried to migrate oracle to PostgreSQL 11. x by using Ora2PG. The below error was encountered while creating the function suggested by this tool.
Error 1#
LINE 6: Type c_DB_fields is Varray(10) of varchar(100);
CONTEXT: invalid type name "c_DB_fields is Varray(10) of varchar(100)"
CONTEXT: invalid type name "c_DB_fields is Varray(10) of varchar(100)"
Error2# (For oracle db link ). I tried to create extension as suggested :
WARNING: 'foreign data wrapper' is a beta feature!
HINT: To suppress this warning, set the 'ysql_beta_feature_foreign data wrapper' yb-tserver gflag to true.
(Set 'ysql_beta_features' yb-tserver gflag to true to suppress the warning for all beta features.)
CREATE EXTENSION
Query returned successfully in 4 secs 588 msec.
(Set 'ysql_beta_features' yb-tserver gflag to true to suppress the warning for all beta features.)
CREATE EXTENSION
Query returned successfully in 4 secs 588 msec.
Error3#
ERROR: syntax error at or near "TABLE"
DETAIL: Internal error: Catalog Version Mismatch: A DDL occurred while processing this query. Try again.
SQL state: XX000
ERROR: syntax error at or near "TABLE"
DETAIL: Internal error: Catalog Version Mismatch: A DDL occurred while processing this query. Try again.
SQL state: XX000
Error4#
ERROR: syntax error at or near "DBMS_SQL"
LINE 47: DBMS_SQL.PARSE(source_cursor,sqlstmt,dbms_sql.v7);
^
LINE 47: DBMS_SQL.PARSE(source_cursor,sqlstmt,dbms_sql.v7);
^
Error5#
ERROR: relation "c_get_smtp_host_name" does not exist CONTEXT: compilation of PL/pgSQL function "sendmail" near line 7 SQL state: 42P01
Error6#
ERROR: schema "utl_smtp" does not exist
LINE 13: l_conn utl_smtp.connection;
^
SQL state: 3F000
Character: 447
LINE 13: l_conn utl_smtp.connection;
^
SQL state: 3F000
Character: 447
SQL state: 42601
Character: 2057