61.11 IS_ADMIN Function

This function checks whether the given user is a business administrator for at least one workflow in this application.

Syntax

APEX_WORKFLOW.IS_ADMIN (
    p_user           IN VARCHAR2 DEFAULT apex_security.g_user,
    p_application_id IN NUMBER   DEFAULT NULL )
RETURN BOOLEAN;

Parameters

Parameter Description
p_user The user to check for. Default is logged-in user.
p_application_id The application to check for. Default behavior checks against all applications in the workspace.

Returns

TRUE if the user given by p_user is defined as a Business Admin for at least one workflow in the given application. Otherwise FALSE.

Example

declare
    l_is_admin boolean;
begin
    l_is_admin := apex_workflow.is_admin(
        p_user => 'stiger'
    );
    if l_is_admin then
        dbms_output.put_line('stiger is a business administrator');
    end if;
end;