Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Validating type PL/SQL Error + Error Message leads to non sense?

Sasha GomanukeJan 12 2021 — edited Jan 12 2021

Hi, guys.
Would You clarify, how i can view text of exception that PL/SQL Error validation throws?
It's always overrided by required Error Message value. But APEX inline help gives us example:
Enter a PL/SQL expression that raises an error as the basis for this validation.
To pass the validation, and not raise the sepcified error, when the employee is in department 30:

begin
    if :P2_DEPTNO <> 30 then
        raise_application_error( -20000, 'Employee is in Department ' || :P2_DEPTNO || ' and not Department 30' );
    end if;
end;

In the same time it tells us to fill Error Message:
Enter the text to be displayed in the event that the validation does not pass.
Where is the sense of raise_application_error in PL/SQL Error code? How i can get that message as validating result?

This post has been answered by Prze-moC on Jan 12 2021
Jump to Answer
Comments
Post Details
Added on Jan 12 2021
7 comments
2,832 views