SAP S/4HANA Price Condition Mapping with Pricefx

This article describes the mappings used by the “SAP S/4HANA Price Condition Integration with Pricefx” package.

Integration Flows

Build SAP S/4HANA Price Condition Batch Create Request from Pricefx Price Condition Records

This integration flow transforms the Price Condition Records from Pricefx to Price Condition create request of S/4HANA OData service. It consists of these steps:

  1. Determine whether it is a purchasing or a sales condition request.

  2. Extract only required information from the Pricefx quote response.

  3. Map to A_SlsPrcgConditionRecordEntityPOST or A_PurgPrcgConditionRecordEntityPOST XML request.

  4. Add pricing scales to the request.

Extract Error Message from Condition Record Response from SAP S/4HANA

This integration flow extracts the main content of the Price Condition create response from SAP S/4HANA OData service. It consists of XSLT which extracts only useful elements and removes namespace from the XML message.

Message Mappings

This package contains mappings which map all the required fields from Pricefx Product Extension response to SAP S/4HANA Price Condition batch request. You should modify these mappings according to your needs.

The sample A_SlsPrcgConditionRecordEntityPOST or A_PurgPrcgConditionRecordEntityPOST XML schema contains only the fields used by the mappings and integrations. It is generated by the OData adapter when the query is specified. You could include your own A_SlsPrcgConditionRecordEntityPOST or A_PurgPrcgConditionRecordEntityPOST XML schema or download one from SAP API Reference.

Required Mappings for Creating Price Conditions in SAP S/4HANA

Sales Condition – Price List, LPG

Sales Condition – Price Records

Purchasing Condition – Price List, LPG

Sales Condition – Price List, LPG

Sales Condition – Price Records

Purchasing Condition – Price List, LPG

Message Mapping Build SAP S/4HANA Price Condition Batch Create Request from Pricefx Price Condition Records

Message Mapping Build SAP S/4HANA Purchasing Price Condition Batch Create Request from Pricefx Price Condition Records

Message Mapping Build SAP S/4HANA Purchasing Price Condition Batch Create Request from Pricefx Price Condition Records

Message Mapping Build SAP ACK Product Extension Upsert Request from Simplified Price Condition Response

Message Mapping Build SAP ACK Product Extension Upsert Request from Simplified Price Condition Response

Message Mapping Build SAP ACK Product Extension Upsert Request from Simplified Price Condition Response

Message Mapping Extract Price Condition Keys from SAP ACK Product Extension in Pricefx

Message Mapping Extract Price Condition Keys from SAP ACK Product Extension in Pricefx

Message Mapping Extract Price Condition Keys from SAP ACK Product Extension in Pricefx

Message Mapping Extract Application Type from Pricefx Price Condition Records

Message Mapping Extract Application Type from Pricefx Price Condition Records

Message Mapping Extract Application Type from Pricefx Price Condition Records

 

Message Mapping Extract Quote Information

 

Update Price Conditions

Three mappings are used in Price Condition updates:

  1. Patch the existing Price Condition.

  2. Patch the validity of the Price Condition.

  3. Get the Price Condition record from Product Extension in Pricefx.

Message Mapping Build SAP S/4HANA Condition Record Patch Request from Pricefx Price Condition Records

The sample A_SlsPrcgConditionRecordEntityPATCH XML schema contains only the fields used by the mappings and the integrations. You could include your own A_SlsPrcgConditionRecordEntityPATCH XML schema. Turning on the OData batch mode is mandatory here.

Message Mapping Build SAP S/4HANA Condition Record Validity Patch Request from Pricefx Price Condition Records

The sample A_SlsPrcgCndnRecdValidityEntityPATCH XML schema contains only the fields used by the mappings and integrations. You could include your own A_SlsPrcgCndnRecdValidityEntityPATCH XML schema. Turning on the OData batch mode is mandatory here.

Message Mapping Extract Price Condition Keys from SAP ACK Product Extension in Pricefx

This mapping simplifies the Product Extension response from Pricefx so that it can be easily used in XSLT transformation later in the flow.

Delete Price Condition

Two mappings are used in Price Condition updates:

  1. Delete the existing Price Condition.

  2. Get the Price Condition record from Product Extension in Pricefx

Message Mapping Build SAP S/4HANA Delete Condition Record Patch Request from Pricefx Price Condition Records

The sample A_SlsPrcgConditionRecordEntityPatchDelete XML schema contains only the fields used by the mappings and the integrations. You could include your own A_SlsPrcgConditionRecordEntityPatchDeleteXML schema. Turning on the OData batch mode is mandatory here.

Message Mapping Extract Price Condition Keys from SAP ACK Product Extension in Pricefx

This mapping simplifies the Product Extension response from Pricefx so that it can be easily used in XSLT transformation later in the flow.