Symptom
When creating the sales order referencing to a quotation, Customer Reference number is not copied from Quotation to Sales order.
Environment
SAP S/4HANA Cloud Public Edition
Reproducing the Issue
- Open app Create Sales Order
- Create a sales order with referent to a quotation
- Customer Reference number is not copied from quotation to sales order
Cause
This is the system standard behavior.
Resolution
To meet the requirement of copying these fields, a Business Add-In can be implemented. Refer to below document and follow the general steps.
Custom Logic: Data Transfer and Copying Requirements for Sales Documents
-
With the Custom Logic app, implement custom logic for the following Business Add-Ins (BAdIs) and assign a unique filter value to it:
Business Add-In (BAdI) Business Context Data Transfer for Sales Document Headers Sales: Sales Document -
Make the following settings in your configuration environment:
-
Perform the Define Data Transfer and Copying Requirements for Sales Documents configuration activity for the implementation type Business Add-In (BAdI): You can define a routine number for the following process enhancement options:
-
Data Transfer for Sales Document (Header)
-
-
Detailed steps and sample code for reference:
1. Implement BAdI Data Transfer for Sales Document Headers (SD_SLS_DATA_TRANSFER_HEAD) via Custom Logic app in the following way
- Choose an Enhancement ID (will be used in SSCUI 103089 later)
- Insert the following coding to get Customer Reference from Quotation:
* First of all assign existing field values to output parameter:
move-corresponding salesdocument_in to salesdocument_out.
* Read Customer Reference from preceeding document
Select single purchaseorderbycustomer from I_SalesQuotation with privileged access where salesquotation = @salesdocument_in-referencesddocument into @salesdocument_out-purchaseorderbycustomer.
2. Configure Customizing
- Configuration activity 103089: Define Data Transfer and Copying Rqmts for Sales Document
- Configuration activity 102905: Set Copying Control: Sales Document to Sales Document
See Also
Keywords
KBA , SD-SLS-GF-CU-2CL , Customizing (Public Cloud) , How To
SAP Knowledge Base Article - Public