59.16 CREATE_USER_GROUP Procedure
This procedure creates a user group when you are using Oracle APEX Accounts authentication.
To execute this procedure within the context of an APEX application, the current user must be an APEX workspace administrator and the application must permit modification of the workspace repository.
Note:
This procedure operates on the native APEX user accounts repository and is only applicable to applications configured with Oracle APEX Accounts authentication.
Syntax
APEX_UTIL.CREATE_USER_GROUP (
p_id IN NUMBER DEFAULT NULL,
p_group_name IN VARCHAR2,
p_security_group_id IN NUMBER DEFAULT NULL,
p_group_desc IN VARCHAR2 DEFAULT NULL );
Parameter
Parameter | Description |
---|---|
p_id |
Primary key of group. |
p_group_name |
Name of group. |
p_security_group_id |
Workspace ID. |
p_group_desc |
Descriptive text. |
Example
The following example demonstrates how to use the CREATE_USER_GROUP
procedure to create a new group called Managers
with a description of text
. Pass NULL for the p_id
parameter to enable the database trigger to assign the new primary key value. Pass NULL for the p_security_group_id
parameter to default to the current workspace ID.
BEGIN
APEX_UTIL.CREATE_USER_GROUP (
p_id => null, -- trigger assigns PK
p_group_name => 'Managers',
p_security_group_id => null, -- defaults to current workspace ID
p_group_desc => 'text');
END;
Parent topic: APEX_UTIL