2
votes

I recently migrate my application from APEX 4.2 to 5.0. And now when i try to log in, error message shows up like this.

ORA-20987: APEX - User nobody requires ADMIN privilege to perform this operation. - Contact your application administrator.

it happens when preforming the login. even login with the blank credentials. after login pressed it checks for the following,

DECLARE  l_err_mesg  VARCHAR2(500);  
BEGIN 
  IF APEX_UTIL.GET_ACCOUNT_LOCKED_STATUS(p_user_name => :P101_USERNAME ) then
    l_err_mesg := '<span style="color: red"> Account currently locked.  </span>';
  END IF;
  RETURN l_err_mesg;   
EXCEPTION WHEN OTHERS THEN
raise_application_error(-20001,'An error was encountered - '||SQLCODE||' -ERROR- '||SQLERRM);
END;

Please tell me what am I missing with this.

1
Are you sure this code is causing the error? Can you login without executing this?Typo
Yes i can login without executing this.Thusira Dissanayake

1 Answers

3
votes

With Oracle Application Express 5.0, employing APEX_UTIL to manage workspace users and groups requires specific configuration. The default settings in APEX5 will provide give you an error when you employ APEX_UTIL for workspace users and groups

If you write and test code in SQL-Developer or SQLPlus, you will not likely encounter this error until you paste your code into APEX. The change is simple:

Go to: Edit Application Properties > Security > Runtime API Usage

You’ll find this as the very last item below database session. Add a check mark to permit “Modify Workspace Repository” as shown in the image below.

enter image description here

Saving this change to your Application Properties will clear the error.

Documentation

Source 1

Source 2