After exporting an apex application using separated files mode available on apex web console, I tried to import it into another workspace using sqlplus with the following command
SQL*Plus: Release 19.0.0.0.0 - Production on Fri Apr 28 10:36:04 2023
Version 19.18.0.0.0
Copyright (c) 1982, 2022, Oracle. All rights reserved.
Last Successful login time: Fri Apr 28 2023 10:35:33 -03:00
Connected to:
Oracle Database 19c Standard Edition 2 Release 19.0.0.0.0 - Production
Version 19.17.0.0.0
SQL> declare
2 l_workspace_id number;
3 n_exists_app number(1);
4 n_application_id number;
5 begin
6 select workspace_id into l_workspace_id
7 from apex_workspaces
8 where workspace = USER||'_WS';
9
10 apex_application_install.set_workspace_id( l_workspace_id );
11 APEX_APPLICATION_INSTALL.GENERATE_APPLICATION_ID;
12 APEX_APPLICATION_INSTALL.GENERATE_OFFSET;
13 apex_application_install.set_schema( USER );
14 apex_application_install.set_application_alias( USER||'_APP' );
15 APEX_APPLICATION_INSTALL.SET_APPLICATION_NAME(p_application_name => USER||'_APP');
16 end;
17 /
at the end of installation, during execution of script end_environment.sql, the following error occurrs
--application/end_environment
begin
*
ERROR at line 1:
ORA-02091: transaction rolled back
ORA-02291: integrity constraint (APEX_220200.WWV_FLOW_NAV_LIST_FK) violated -
parent key not found
ORA-06512: at "APEX_220200.WWV_FLOW_SECURITY", line 1999
ORA-06512: at "APEX_220200.WWV_FLOW_IMP", line 1104
ORA-06512: at "APEX_220200.WWV_FLOW_IMP", line 1130
ORA-06512: at "APEX_220200.WWV_FLOW_IMP", line 1168
ORA-06512: at line 2
What could be causing this error?
p.s. Apex version: 22.2.0