31.4 DELETE_MESSAGE Procedure

Use this procedure to delete a translatable text message in the specified application.

Syntax

APEX_LANG.DELETE_MESSAGE (
    p_id    IN NUMBER )

Parameters

Table 31-4 DELETE_MESSAGE Parameters

Parameter Description
p_id The ID of the text message.

Example

The following example demonstrates the deletion of an existing translatable text message.

begin
    --
    -- If running from SQL*Plus or SQLcl, we need to set the environment
    -- for the Oracle APEX workspace associated with this schema.
    -- The call to apex_util.set_security_group_id is not necessary if
    -- you're running within the context of the App Builder or an APEX
    -- application.
    --
    for c1 in (select workspace_id
                from apex_workspaces
              where workspace = 'HR_DEV') loop
        apex_util.set_security_group_id( c1.workspace_id );
        exit;
    end loop;

    -- Locate the ID of the specific message and delete it
    for c1 in (select translation_entry_id
                from apex_application_translations
               where application_id = 63969
                and translatable_message = 'TOTAL_COST'
                and language_code = 'ja') loop
        apex_lang.delete_message(
            p_id => c1.translation_entry_id );
        commit;
        exit;
    end loop;
end;
/