I'm getting an > Internal error,
Could not validate caller for user "" when parsing
- error_backtrace: ----- PL/SQL Call Stack -----
object line object
handle number name
0xbcede5c0 1033 package body APEX_190200.WWV_FLOW_ERROR.INTERNAL_GET_ERROR
0xbcede5c0 1101 package body APEX_190200.WWV_FLOW_ERROR.INTERNAL_ADD_ERROR
0xbcede5c0 1493 package body APEX_190200.WWV_FLOW_ERROR.RAISE_INTERNAL_ERROR
0xbcede5c0 1574 package body APEX_190200.WWV_FLOW_ERROR.RAISE_MASKED_INTERNAL_ERROR
0xd11c9840 501 package body SYS.WWV_DBMS_SQL_APEX_190200.PARSE_AS_USER
0xd11d27f0 2006 package body APEX_190200.WWV_FLOW_DYNAMIC_EXEC.PARSE_AS_USER
0xd11d27f0 2513 package body APEX_190200.WWV_FLOW_DYNAMIC_EXEC.RUN_BLOCK5
0xd11d27f0 1301 package body APEX_190200.WWV_FLOW_DYNAMIC_EXEC.GET_PLSQL_EXPR_RESULT_BOOLEAN
0xbc8fef90 207 package body APEX_190200.WWV_FLOW_CONDITIONS.STANDARD_CONDITION
0xbcd71460 71 package body APEX_190200.WWV_FLOW_META_UTIL.IS_OK_TO_DISPLAY
0xbcd71460 118 package body APEX_190200.WWV_FLOW_META_UTIL.IS_OK_T~
- component: APEX_APPLICATION_PAGE_REGIONS Region1
when I call a PL/SQL procedure before header on Page in Oracle Apex:
begin
doSomething;
end;
The procedure has the CREATE_SESSION procedure in it:
CREATE OR REPLACE PROCEDURE doSomething
AS
BEGIN
apex_session.create_session (
p_app_id => 100,
p_page_id => 1,
p_username => 'doSomething USER');
insert into table1 (column1, column1) values (val1, val2);
apex_session.delete_session (v('APP_SESSION'));
END;
The doSomething procedure seems to run fine as, after I get the Internal error, I can check table1 and see that data as correctly been inserted into the table. My main problem now is getting the page to do something else like branch to a new modal but the Internal error is preventing that as nothing on the page renders, no regions, no buttons, nothing.
Is they a way to either fix the error or just bypass it altogether? I've tried removing the component it supposedly has the issue with, but the same error comes back on a different component
When calling a procedure from within apex, that procedure has the context of the current apex session. create_session
is only needed outside of an APEX context, for example in code that is invoke from a scheduler job but that needs a session.
So what I suspect is happening is that the apex_session.delete_session (v('APP_SESSION'));
is destroying the apex session you are correctly connected as in your application. Just get rid of any apex_session
calls in your application or in any code called from your application.