cancel
Showing results for 
Search instead for 
Did you mean: 

Splitting of a CSV File with Multiple Records into Multiple XML File

gautam_poddar2
Participant
0 Kudos

Dear All,

<b> I am doing a Scenario of CSV to XML Files. I am using BPM for the same. My incoming CSV File has got multiple records. I want to break this Multiple records into Multiple XML Files having one record each.</b>

Can someone suggest how can I break this rather Split this into Multiple XML Files.

Is Multimapping absoltely necesaary for this. Can't we do this without Multimapping. Can we have some workaround in the FCC parameters that we use in the Integration Directory.

Kindly reply ASAP. Thanks a lot to all in anticipation.

Pls Help.

Best Regards

Chakra and Somnath

Accepted Solutions (1)

Accepted Solutions (1)

former_member91687
Active Contributor
0 Kudos

Hi,

Is it that you have one file with multiple records coming in? If so you can set the records to one so that the single file with multiple records can be processed as multiple messages.

Else if you are going for splitting the messages say a 1:N mapping, you can work with Enhanced Interface Determination where you have the option of using RB_SPLIT/EXTENDED. You do not need a BPM in this case. More information on this can be read in the SAP help library: http://help.sap.com/saphelp_nw04/helpdata/en/42/ed364cf8593eebe10000000a1553f7/frameset.htm

Regards,

Chandra

gautam_poddar2
Participant
0 Kudos

Dear All,

Thanks a lot for the replies. I have already used BPM for all those. Changing them will be a big pain. I want to Spit the Messages because I have an RFC which is called and this updates the Data in SAP. If there are multiple records in one XML File then only the First Recordset is Populated. Other rows of data are not populated, so i want to split the CSV into Mutiple XML Files.

What should be the approach for this case.

Awaiting Replies.

Best regards

Chakra and Somnath

Former Member
0 Kudos

>>>...File then only the First Recordset <<<

--> is MaxOccurs = 1 ?

Than this should be the error.

Regards Mario

Former Member
0 Kudos

Hi,

You could use the Recordsets per Message option in file content conversion.

Set this parameter to 1.

This way you would be sending 1 record per message.

Regards,

Smitha.

Former Member
0 Kudos

<i> If there are multiple records in one XML File then only the First Recordset is Populated. Other rows of data are not populated, so i want to split the CSV into Mutiple XML Files.</i>

This is because you haven't implemented multimapping properly.

In case you are already using multi mapping, make sure that the occurence of the target message and the target interface is changed to 0...unb.

Regards,

Smitha.

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

><i>I have already used BPM for all those. Changing them will be a big pain. I want to Spit the Messages because I have an RFC which is called and this updates the Data in SAP</i>

Can you give us the entire flow ?

I would still suggest making the change and going for multi mapping without BPM.

Please refer to this blog,

/people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible

Regards

Bhavesh

gautam_poddar2
Participant
0 Kudos

Dear All,

I am trying to do the Multimapping, and have 0....unbounded also. Someways it is not working.

<b>

Smitha please tell me one thing...Assigning the Recordsets per Message to 1, does it mean that it will write multiple XML Files as I want.</b>

Also I am usinf Set to Read only. So once the File is read it becomes RA from A. Then will it write the other Records.

I have to use a BPM because there are certain dependencies that are there for the entire Process Flow. I cannot do without a BPM.

Awaiting a reply. Thanks a lot in anticipation.

Best Regards

Chakra and Somnath

Former Member
0 Kudos

Hi,

The RecordSetsPerMessage option when set to 1, would send 1 message at a time to the integration engine.

So the mapping would be called for each message, and hence 1 will create multiple target messages.

For multimapping, recheck the following:

1. Make sure that the target MT and MI is 0 to unb

2. If this is right, then make sure that the mapping you have specified is right.

That is, make sure that the target element which is to repeat multiple times is mapped to the proper source element.

Regards,

Smitha.

gautam_poddar2
Participant
0 Kudos

Thanks a lot for ur Answers..I solved it

regards

Chakra and Somnath

Former Member
0 Kudos

Hi Somnath

Can you please let me know how did you solve your above scenario.

I have the similar problem where i need to map an XML with multiple records to BAPI ( where the occurance is 1).

PS: Points would rewarded.

Thanks

Rakesh

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Chakra and Somnath,

you have to design a "multi-mapping"

In Integration Repository goto software component SAP BASIS.

There are good samples for multi-mapping. Open the corresponding message mapping. Then you will get an idea of multi-mapping

Regards Mario

sridharreddy_kondam
Active Contributor
0 Kudos

Hi Somnath,

I suggest is use 0..Unbounded occurences for target structure, mean which holds the details for all the records,

And the do Mapping with source structure node to target stucture node... and it will work... try once...

Try this without using BPM... You can do this without BPM

Thanks and Regards,

sridhar