cancel
Showing results for 
Search instead for 
Did you mean: 

Need help on the UDF

sahithi_moparthi
Contributor
0 Kudos

Hi,

I have a query on the below Scenario.

<Recordset>
     <Field1>100</Field1>
      <Field1>Rail</Field2>
       <Field1>1</Field3>
</RecordSet>
<Recordset>
     <Field1>101</Field1>
      <Field1>Van</Field2>
       <Field1>2</Field3>
</RecordSet>
<Recordset>
     <Field1>100</Field1>
      <Field1>Car</Field2>
       <Field1>3</Field3>
</RecordSet>

Please find the below query:
1.I have to group based on the field1.So,in the above example i have 3 Recordset,in which 2 have the same value in field1 so i have to group and  need to create one IDOC.
2.In IDOC,i need to repeat the Item segment,which depends on the Field2.As per the above example,i need to cretae 2 Item segments.

Output should be like:

IDOC -1
Header 100
Item   Rail
Item Car

IDOC-2
Header-101
Item-Van

Could any one please help me how to acheive this functionality.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Santhoshi,

Please see attached screenshots. You dont need udf for this.

Thanks

Beena

Former Member
0 Kudos

Hi Sathoshi,

This can also be achieved writing a simple XSLT mapping implementing the Grouping logic.

Please let me know if you are going for it. I can help you with sample code.

Thank you.

Regards,

Subbalaxmi Musunuri

Answers (0)