1

After an upgrade of a very old app to APEX 20.2, everything works surprisingly well except for a few pages where all buttons and LOVs throw one of two errors when calling WWV_FLOW_DYNAMIC_EXEC.PARSE_AS_USER:

Could not validate caller for user "" when parsing
select select 1 
  from TD_PNART
could not validate env for schema "APEX_PUBLIC_USER":context=, parse_as_schema=,
parse_as_schema_override=,sgid=, curr_flow_sgid=994328456202381, flow_id=220,when parsing

I've tried everything from updating the authorization scheme, searching every piece of SQL for something that could have expired the schema user, recreating the object, revalidating ORDS, etc. but the error appears each time and SQL Trace/APEX Trace doesn't provide further information. I can't find the issue on Google or Oracle Support either.

How can I diagnose an internal error such as this?

- error_backtrace: ----- PL/SQL Call Stack -----
  object      line  object
  handle    number  name
0x6d5e0d58       947  package body APEX_200200.WWV_FLOW_ERROR.INTERNAL_GET_ERROR
0x6d5e0d58      1015  package body APEX_200200.WWV_FLOW_ERROR.INTERNAL_ADD_ERROR
0x6d5e0d58      1407  package body APEX_200200.WWV_FLOW_ERROR.RAISE_INTERNAL_ERROR
0x6d5e0d58      1488  package body APEX_200200.WWV_FLOW_ERROR.RAISE_MASKED_INTERNAL_ERROR
0x825ab978       521  package body SYS.WWV_DBMS_SQL_APEX_200200.PARSE_AS_USER
0x73579878      1698  package body APEX_200200.WWV_FLOW_DYNAMIC_EXEC.PARSE_AS_USER
0x73579878      2378  package body APEX_200200.WWV_FLOW_DYNAMIC_EXEC.SELECT_INTO_I
0x73579878      2459  package body APEX_200200.WWV_FLOW_DYNAMIC_EXEC.SELECT_NUM
0x73579878      1263  package body APEX_200200.WWV_FLOW_DYNAMIC_EXEC.DO_ROWS_EXIST
0x8239fac8       290  package body APEX_200200.WWV_FLOW_CONDITIONS.STANDARD_CONDITION
0x851816e0        71  package body APEX_200200.WWV_FLOW_META_UTIL.IS_OK_TO_DISPLAY
3
  • 1
    Does your application have direct calls to WWV_FLOW_DYNAMIC_EXEC? Commented Apr 26, 2021 at 2:49
  • Not that I can see. I'm updating the question with the stack from debug Commented Apr 26, 2021 at 14:26
  • Sounds like a bug - something to raise with Oracle support I think. Commented Apr 27, 2021 at 0:05

1 Answer 1

1

An engineer at Oracle was able to solve this issue, which had a completely unexpected solution:

Just for the benefit of other developers who might run into the same problem. The issue was that the page still contained page items of type 'Textfield with Calculator' which has been desupported in APEX 5.0. After rending such a page item, the remaining page rendering was just broken which resulted in the above error. I have filed bug #32828261 to finally remove that item type and convert existing items to Textfields.

Workaround:

Manually update existing page items to Textfields.

select workspace, application_id, application_name, page_id, page_name, item_name
  from apex_application_page_items
 where display_as_code = 'NATIVE_TEXT_WITH_CALCULATOR'
 order by workspace, application_id, page_id, item_name
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.