PO Approval Error "ORA-06502: PL/SQL: Numeric Or Value Error" For POs With Higher Number of Lines (Doc ID 1516785.1)

Last updated on JANUARY 15, 2013

Applies to:

Oracle Purchasing - Version 12.1.3 and later
Information in this document applies to any platform.

Symptoms

Purchase Order (PO) Approval failing with the following error message for purchase orders with large number of lines.

ORA-06502: PL/SQL: numeric or value error: character string buffer too small ORA-06512: at "APPS.WF_NOTIFICATION", line 5774 ORA-06512: at line 6

Steps:
  - Create a PO using the Purchasing responsibility.
  - Submit PO for Approval.
  - When approver chooses approve in approval notification the error message above displays.


WFSTAT.sql output shows the complete error message as follows:

    PO_PO_APPROVE_PDF        #MAIL WF_ERROR          
    [WF_ERROR] ERROR_MESSAGE=3835: Error '-20002 - ORA-20002: 2018: Unable to generate the notification XML.
    Caused by: 2020: Error when getting notification content.
    Caused by: ORA-06502: PL/SQL: numeric or value error: character string buffer too small
            
    Wf_Notification.runFuncOnBody(8986179, text/html)
    Wf_Notification.GetBody(8986179, text/html)
    WF_NOTIFICATION.GetFullBody(nid => 8986179, disptype => text/html)     
    WF_MAIL.GetLOBMessage3(nid => 8986179, r_ntf_pref => MAILHTM2)' encountered during execution of Generate function 'WF_XML.Generate'
    for event 'oracle.apps.wf.notification.send'.
    ERROR_STACK=
    WF_MAIL.GetLOBMessage3(8986179, WFMAIL, 2020: Error when getting notification content.
    Caused by: ORA-06502: PL/SQL: numeric or value error: character string buffer too small  
             
    Wf_Notification.runFuncOnBody(8986179, text/html)
    Wf_Notification.GetBody(8986179, text/html)   
    WF_NOTIFICATION.GetFullBody(nid => 8986179, disptype => text/html)       
    WF_MAIL.GetLOBMessage3(nid => 8986179, r_ntf_pref => MAILHTM2), Step -> Getting text/html body)
    WF_XML.GenerateDoc(oracle.apps.wf.notification.send, 8986179)       
    WF_XML.Generate(oracle.apps.wf.notification.send, 8986179)
    WF_XML.Generate(oracle.apps.wf.notification.send, 8986179)
    Wf_Event.setMessage(oracle.apps.wf.notification.send, 8986179, WF_XML.Generate)
    Wf_Event.dispatch_internal()

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms