ORA-06502 While Sending The Email Using APEX_MAIL Package
(Doc ID 2955381.1)
Last updated on JUNE 16, 2023
Applies to:
Oracle Application Express (APEX) - Version 21.1 and laterOracle Cloud Infrastructure - Database Service - Version N/A and later
Information in this document applies to any platform.
Symptoms
While trying to send an email using the APEX_MAIL package the action is not getting processed and the mail remained in Queue without any error or failing with the error ORA-06502 during the delivery or when executing the job.
Scenario 1: When the scheduled job is executed, using the command EXEC dbms_scheduler.run_job('ORACLE_APEX_MAIL_QUEUE'); the following error is
noticed.
ERROR at line 1:
ORA-06502: PL/SQL: numeric or value error: character to number conversion
error
ORA-06512: at "SYS.UTL_SMTP", line 110
ORA-06512: at "SYS.UTL_SMTP", line 235
ORA-06512: at "SYS.UTL_SMTP", line 215
ORA-06512: at "SYS.UTL_SMTP", line 630
ORA-06512: at "SYS.UTL_SMTP", line 641
ORA-06512: at "APEX_210100.WWV_FLOW_MAIL", line 162
ORA-06512: at "APEX_210100.WWV_FLOW_MAIL", line 1680
ORA-06512: at line 1
ORA-06512: at "SYS.DBMS_ISCHED", line 242
ORA-06512: at "SYS.DBMS_SCHEDULER", line 566
ORA-06512: at line 1
Scenario 2 : The mail entry is created in the Mail Queue and the job run is showing as executed but the ORA-06502 is noticed in the Mail Q as the delivery was failed and the scheduler run shows the below error.
"ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Cause |
Solution |
References |