cancel
Showing results for 
Search instead for 
Did you mean: 

Processing from 2nd Line of CSV file

0 Kudos

Hi,

we are recieveing a CSV file as attachement through mail, wherein I would need to strat processing from 2nd line of the CSV file.

can you please suggest how can I process as above directly from mail.


Thank you.

John

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello,

>> wherein I would need to strat processing from 2nd line of the CSV file.

I think only  specifying "xml.documentSkipFirstRows" parameter will not help u to to skip rows, check Rene's reply

http://scn.sap.com/thread/1223739

Thanks

Amit Srivastava

0 Kudos

Hi Amit/Hareesh,

No still not working though i set the module parameters as above.

Here we are using mail adapter where we are just accessing directly the attachement payload.

can you please specify how can I get this.

former_member184720
Active Contributor
0 Kudos

First module should be payload swapbean so that your attachment becomes main payload

Then you should use the message tranformation bean..

If you did that.. can you please share the screenshots of the configuration..

0 Kudos

Yes Hareesh. First Module is PayloadSwapBean and then Message TransformBean.

In Module configuration, we are using conversion type as SimplePlain2XML.

can you tell how can I get this done.

former_member184720
Active Contributor
0 Kudos

I see that you have added the module but the relevant parameters are missing for payload swap beam.

Please add the paramters as per the below blog to convert the attachment to main payload.(swap.keyname &swap.keyvalue)

Also for the MTB, please add another paramter - xml.documentSkipFirstRows and set it to 1.

Message was edited by: Hareesh Gampa

0 Kudos

Hi Hareesh,

I am not sending/having the attachement to NFS locstion. I am just accessing te attachement directly from mail using the module parameters, but while accessing the attachement, i want to skip first line of the  csv file.

former_member184720
Active Contributor
0 Kudos

understood John but for that you still need to set your attachment as main payload.

so those 2 parameters help you to covert the attachment to main payload.

After that you can use the MTB module...

Former Member
0 Kudos

Hello,

The value of parameter "xml.processFieldNames" should be "fromFile", so change it and then check?

BTW, i am assuming that u are properly using payloadswap bean as already pointed out by Hareesh.

Thanks

Amit Srivastava

Answers (1)

Answers (1)

former_member184720
Active Contributor
0 Kudos

sorry i over looked.

Use the payload swapbean in the mail adapter to convert the attachment to main payload and then using Message Tranformation Bean


and the parameter "xml.documentSkipFirstRows" can be used to ignore the first lines..

Message was edited by: Hareesh Gampa