Using Oracle Application Express 4.2.5.00.08 we have the following recurring issue:
- We develop on a development DB.
- We export the whole application from the development DB to an SQL*Plus script file.
- We import (via either SQL*Plus or APEX admin frontend, does not matter) the whole script file to a different (test/prod) DB.
- Five (the same each time) of all page plugs get their display points messed up in the imported application.
The exported-from-DEV page plug creation snippet looks like:
declare
s varchar2(32767) := null;
l_clob clob;
l_length number := 1;
begin
s:=s||'Revision Comments';
wwv_flow_api.create_page_plug (
p_id=> 36035377787100554 + wwv_flow_api.g_id_offset,
p_flow_id=> wwv_flow.g_flow_id,
p_page_id=> 68,
p_plug_name=> 'Toolbar3',
p_region_name=>'',
p_parent_plug_id=>36001157224505179 + wwv_flow_api.g_id_offset,
p_escape_on_http_output=>'Y',
p_plug_template=> 35698556626931435+ wwv_flow_api.g_id_offset,
p_plug_display_sequence=> 105,
p_plug_new_grid => false,
p_plug_new_grid_row => true,
p_plug_new_grid_column => true,
p_plug_display_column=> null,
p_plug_display_point=> 'REGION_POSITION_02',
p_plug_item_display_point=> 'ABOVE',
p_plug_source=> s,
p_plug_source_type=> 'STATIC_TEXT',
p_translate_title=> 'Y',
p_plug_query_row_template=> 39496105155901584+ wwv_flow_api.g_id_offset,
p_plug_query_headings_type=> 'QUERY_COLUMNS',
p_plug_query_num_rows => 15,
p_plug_query_num_rows_type => 'NEXT_PREVIOUS_LINKS',
p_plug_query_row_count_max => 500,
p_plug_query_show_nulls_as => ' - ',
p_plug_display_condition_type => 'SQL_EXPRESSION',
p_plug_display_when_condition => ':P68_ID_BUS_DQI_DATA IS NOT NULL',
p_pagination_display_position=>'BOTTOM_RIGHT',
p_plug_customized=>'0',
p_plug_caching=> 'NOT_CACHED',
p_plug_comment=> '');
end;
/
When we export the whole app again from the test/production (after having it imported from the script file) and do a line-by-line comparison, the page plug's creation code snippet looks like...
declare
s varchar2(32767) := null;
l_clob clob;
l_length number := 1;
begin
s:=s||'Revision Comments';
wwv_flow_api.create_page_plug (
p_id=> 36035377787100554 + wwv_flow_api.g_id_offset,
p_flow_id=> wwv_flow.g_flow_id,
p_page_id=> 68,
p_plug_name=> 'Toolbar3',
p_region_name=>'',
p_parent_plug_id=>36001157224505179 + wwv_flow_api.g_id_offset,
p_escape_on_http_output=>'Y',
p_plug_template=> 35698556626931435+ wwv_flow_api.g_id_offset,
p_plug_display_sequence=> 105,
p_plug_new_grid => false,
p_plug_new_grid_row => true,
p_plug_new_grid_column => true,
p_plug_display_column=> null,
p_plug_display_point=> 'BODY_3',
p_plug_item_display_point=> 'ABOVE',
p_plug_source=> s,
p_plug_source_type=> 'STATIC_TEXT',
p_translate_title=> 'Y',
p_plug_query_row_template=> 39496105155901584+ wwv_flow_api.g_id_offset,
p_plug_query_headings_type=> 'QUERY_COLUMNS',
p_plug_query_num_rows => 15,
p_plug_query_num_rows_type => 'NEXT_PREVIOUS_LINKS',
p_plug_query_row_count_max => 500,
p_plug_query_show_nulls_as => ' - ',
p_plug_display_condition_type => 'SQL_EXPRESSION',
p_plug_display_when_condition => ':P68_ID_BUS_DQI_DATA IS NOT NULL',
p_pagination_display_position=>'BOTTOM_RIGHT',
p_plug_customized=>'0',
p_plug_caching=> 'NOT_CACHED',
p_plug_comment=> '');
end;
/
... with the only difference being in the...
p_plug_display_point=> 'BODY_3',
... line.
This, of course, can be fixed manually via APEX frontend for each of the five page plugs, but that is unthinkable to do when 6 environments are in place and each of them should be updated several times a month. Automated deployment tools are in place for all DB development, only this APEX frontend must be taken care of by hand.
Comparison of the apex_040200.wwv_flow_page_plugs data before vs. after the manual, frontend-driven fix showed that only the apex_040200.wwv_flow_page_plugs.plug_display_point got updated from 'BODY_3' back to 'REGION_POSITION_02'. But we don't have privileges to do direct updates of the APEX tables.
I tried searching for some kind of update_page_plug() API procedure, but did not find any.
So, I'm interested in
- either finding the
update_page_plug()procedure directly from APEX APIs, - or fixing this directly in the application, so that the issues stop recurring (since I believe it is something that the original app's developer did not do right, just don't know what that might be).
Any advice, then?