Forum Stats

  • 3,769,240 Users
  • 2,252,937 Discussions
  • 7,874,958 Comments

Discussions

Error installing application

John Vaughan
John Vaughan Member Posts: 196
edited Sep 5, 2008 8:20PM in APEX Discussions
Dear all - our main application export file has now grown to over 15MB,
and we've started having problems installing it into other workspaces.
It's not actually the upload that fails (which some users have
experienced, and seems to be related to an HTTP server timeout), but
the next step; installing it. The browser timeout error happens after
you have loaded the application, but before the page loads that prompts
for the parsing schema and app ID. Clicking on Install from the Export
Repository leads to the same error.

Although we have not yet got
to the bottom of that problem, the received advice seems to be to
install the application using SQL*Plus. Although this seems to
introduce plenty of opportunities for getting it to go wrong, the basic
advice (taken from one of Scott Spadafore's posts on the subject) is:

+"This
is not a normal approach. You'd have to edit the primary application
export file for each new application you want to create. Look through
the file and change references to the "exported" application ID to the
desired application ID. They will be in lines like the following where
I show 9999 as the original ID:+

+wwv_flow.g_flow_id := 9999;+

+wwv_flow_api.remove_flow(9999);+

+wwv_flow_audit.remove_audit_trail(9999);+

+wwv_flow_api.create_flow(+

+ p_id =>9999,+

+ p_display_id=> 9999,+

+ p_alias => 'F9999',+

+ p_owner => 'FOO',+

+For
the "p_owner => 'F00' " case, change the parsing schema FOO to the
new parsing schema, making sure that the schema is actually mapped to
the target workspace.+

+Then you need to look for any text
containing "f?p=9999:..." and change the old application ID to the new
one. There may be none of these in your application but if you find
any, you should also change all of those occurrences in the original
application to use &APP_ID. instead of 9999.+

+Finally, locate
the line: "wwv_flow_api.g_id_offset := 0;" near the top of the file and
change 0 to 1 for the first "new" application, change it to 2 for the
second "new" application, etc. If during import you get any kind of
unique key constraint errors, go back and change the offset to a larger
integer and try again.+

+N.B., this approach cannot be used if your application has been translated."+

However, doing this lead (in our case) to the error:

Illegal security group id value for this schema

and, later in the SQL*Plus prompts:

ORA-20001: Package variable g_security_group_id must be set

Near the beginning of the installation script file, there is the statement:

wwv_flow_api.set_security_group_id(p_security_group_id=>NNNNNNNNNNNNNNNNN);

(where NNNNNNNNNNNNNNNNN
is a large number). Because we are installing from one workspace to
another, and because of the nature of the error message, I tried
replacing this number with the value for the target workspace, obtained
using:

select wwv_flow_api.get_security_group_id() from dual

Having done this, the script ran without error.

Thought I'd post this in case it helps anyone.

Regards,

John.

Comments

  • 60437
    60437 Member Posts: 16,564
    John,

    Thanks for the nice recap of this procedure. If I'm not mistaken, my original post addressed a question where the user was doing this all within the same workspace, so the issue of changing the security group ID API call was not a factor. In your case, where you are changing workspaces, you did exactly the right thing.

    Scott
This discussion has been closed.