Symptom
Value of the Customer Reference (PurchaseOrderByCustomer) field is Not Returned in The Sales Volume App(s)
Environment
SAP S/4HANA Cloud
Reproducing the Issue
- Open a Sales Volume App e.g. Sales Volume - Flexible Analyses
- Add the "Customer Reference" field
- Result shows "#"
Cause
Adding this filed in the standard system would impact performance
Resolution
It is possible to define a custom query that considers the field PurchaseOrderByCustomer (label: Customer Reference) from the sales document.
- Open the “Custom CDS Views”App
- Create and publish a custom CDS view based on I_BillinDocumentItem.
- For this view, select relevant Billing Document item fields, and relevant Billing Document header fields.
- Add also I_BillingDocumentItem._SalesDocument.PurchaseOrderByCustomer and add also billing document header field I_BillingDocumentItem._BillingDocument.BillingDocumentIsTemporary.
- Define a filter as part of this CDS view: " I_BillingDocumentItem._BillingDocument.BillingDocumentIsTemporary != 'X' " (without this filter, draft billing documents would also be considered, which should be avoided).
- Now that the Custom View has been created open the "Custom Analytical Queries" App and create a custom query.
- As data the source, choose the custom CDS view created in steps 1-5.
- Define the query to suit the business requirement.
- The Customer Reference (PurchaseOrderByCustomer) can be used.
Keywords
Flexible Analyses, Detailed Analyses, Customer Reference, PurchaseOrderByCustomer, Sales Volume , KBA , SD-BIL , Billing , SD-FIO-HBA , Analytical Apps , Problem
Product
SAP S/4HANA Cloud Public Edition all versions
SAP Knowledge Base Article - Public