GET_ACCOUNT_LOCKED_STATUS Function

Returns true if the account is locked and false if the account is unlocked. Must be run by an authenticated workspace administrator in a page request context.

Syntax

APEX_UTIL.GET_ACCOUNT_LOCKED_STATUS (
     p_user_name IN VARCHAR2
     ) return boolean
     ;

Parameters

Table: GET_ACCOUNT_LOCKED_STATUS Parameters describes the parameters available in the GET_ACCOUNT_LOCKED_STATUS function.

GET_ACCOUNT_LOCKED_STATUS Parameters

Parameter Description

p_user_name

The user name of the user account


Example

The following example shows how to use the GET_ACCOUNT_LOCKED_STATUS function. Use this function to check if an Application Express user account (workspace administrator, developer, or end user) in the current workspace is locked.

BEGIN
  FOR c1 IN (SELECT user_name FROM wwv_flow_users) loop
    IF APEX_UTIL.GET_ACCOUNT_LOCKED_STATUS(p_user_name => 
c1.user_name) THEN
      htp.p('User Account:'||c1.user_name||' is locked.'); 
    END IF;   
  END LOOP;
END;