Posts

Content Modifier - Concatenate Array Inputs ( Dynamic Parent Node)

Image
   Requirement is to extract the repeated XML node with Dynamic Parent Nodes. Here, we are passing the below payload directly in Content Modifier - Message Body -------------------------------------------------------------------------------------------------------------------- <message>     <header>       <messageId>1</messageId>       <masterMsgId>33300453700</masterMsgId>       <equipment>         <serialNumber>API TestSNVin</serialNumber>         <make>CAT</make>         <model>D100</model>         <nickname>API Test Asset</nickname>       </equipment>       <moduleCode>API TestDeviceSN</moduleCode>       <moduleTime>2022-02-16 10:45:14</moduleTime>       <recei...

Content Modifier - Concatenate Array Inputs

Image
 Requirement is to extract the repeated XML node with Static parent node. Step 1 - Here, I am passing input in the Content modifier itself. Sample Input: <Root> <Employee> <Name>Akshay</Name> <ID>1</ID> </Employee> <Employee> <Name>Sudeep</Name> <ID>2</ID> </Employee> <Employee> <Name>Advik</Name> <ID>3</ID> </Employee> <Employee> <Name>Hirva</Name> <ID>4</ID> </Employee> </Root> ----------------------------------------------------------------------------------------------------------------------------- Step 2 : Declare Property variables to hold the output. Name_Concat  string-join(/Root/Employee/Name, ",") ID_Concat  string-join(/Root/Employee/ID, ",") Below is the config. of the message body tab of the content modifier: -------------------------------------------------- ...

Global Data Store & Variable

Image
 The first iFlow shows how to write a variable (Global) and Write the incoming data to a Data Store. Whereas, in the second iFlow we will fetch data from the data store which was declared in the first iFlow.  First iFlow (Producer) Address : https://refapp-espm-ui-cf.cfapps.eu10.hana.ondemand.com/espm-cloud-web/espm.svc   Write Variable: Write Variables are used to share data across different integration flows (deployed on the same tenant). To consume the variable (either in another step of the same integration flow or in another integration flow), can use a Content Modifier. A variable gets expired after the retention period which is 400 days. Data Store Write Operation: This step performs a Write operation on the transient data store. Entry ID Specify an entry ID that is stored together with the message content. The entry ID must not exceed 255 characters. Details for the entry ID are read from the incoming message. ...

XML to CSV Conversion

Image
 Input to Content Modifier: -------------------------------------------------------------------------------------------------------- <Records>                 <Header>                                 <FieldA>H_ABC</FieldA>                                 <FieldB>H_123</FieldB>                                 <FieldC>H_XXX</FieldC>                                 <FieldD>H_567890</FieldD>                 </Header>                 <Line>             ...

General Splitter

Image
 Demo Scenario : Content Modifier: Body  --------------------------------------------------------- <root xmlns="demo.sap.com"> <shop> <customerReview> <id>001</id> <rating>4</rating> </customerReview> <customerReview> <id>002</id> <rating>1</rating> </customerReview> <customerReview> <id>003</id> <rating>1</rating> </customerReview> <customerReview> <id>004</id> <rating>1</rating> </customerReview> <customerReview> <id>005</id> <rating>1</rating> </customerReview> </shop> </root> --------------------------------------------------------- Please also refer to the below blog for elaborative analysis : https://blogs.sap.com/2020/09/21/sap-cloud-platform-integration-general-splitter/

CSV to XML - Demo

Image
 The converter element enables you to transform an input message in one format to another.  Input: 123, Akshay, CPI Consultant 456, Akshada, Professor CSV to XML Converter : XML Schema: Choose Browse and select the file path to the XML schema file that is used as the basis for message transformation. The XML file schema format is used as the basis for creation of the payload.  Path to Target Element in XSD : XPath in the XML Schema File where the content from CSV has to be placed.  Record Marker in CSV : The corresponding record in the CSV file that has to be considered for conversion. This entry is the first text in every new record of the CSV.  If this value is not specified then all the records would be considered for conversion. Field Separator : If we want to use a field separator that is not available in the dropdown list, manually enter the character in Field Separator in CSV field. If you want to exclude headers in the first line of CSV file for convers...