cancel
Showing results for 
Search instead for 
Did you mean: 

How to remove the footer in the file content conversion

Former Member
0 Kudos

HI

I have receiver structure like this

<Mt_test>

<Node1>

<test1>name1</test1

<test2>name2</test2

<footer>

<test3>name3>

This is the structure. footer segment we need in pay load. so we can't skip anything in the mapping. But target we are using File content conversion. i want to remove the last footer segment in the file. Please help me this.

thanks

Sam

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Sam,

The same (more or less)question is asked from srinivas few minutes ago. Please check sravyas blog for the same approach:

/people/sravya.talanki2/blog/2005/08/11/solution-to-the-problem-encountered-using-variable-substitution-with-xi-sp12

Regards,

---Satish

Former Member
0 Kudos

Hi Satish,

Thank you for very helpful answer. Same concept i am also working on. when i given the parameters like blog i am getting the error. Can you help me this.

Error :

Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'java.lang.Exception: Column value 'test0001' too long (>0 for 0. column) - must stop', probably configuration error in file adapter (XML parser error)': java.lang.Exception: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'java.lang.Exception: Column value 'test00001 (>0 for 0. column) - must stop', probably configuration error in file adapter (XML parser error)'

field separator ,

endseparator is 'nl'

Footer.fieldFixedLengths = 0

Footer.fixedlengthTooShortHandling =Cut

Can you help me this.

Advanced thanks

Sam

Former Member
0 Kudos

Hi Sam,

It seems you are having some config uses. Can you give the payload after message mapping and all the parameters you are using in receiver file content conversion so that somebody can help you out here.

Regards,

---Satish

Former Member
0 Kudos

Hi Satish,

Thank for your quick replay.

attached payload i am receiving after the mapping. i need to eliminate footer node in my file.

Output should be like this.

20100201,200,2345.00

20100218,201,2345.00

But out put i am getting like this

20100201,200,2345.00

20100218,201,2345.00

test0001---> should be remove this in the output file.

Payload:

<ns0:MT_google xmlns:ns0="http://google.com/xi/google">

<Datarow>

<CALDAY>20100201</CALDAY>

<PLANT>200</PLANT>

<ZSTR_PLANT>2345.00;/ZSTR_PLANT>

</Datarow>

<Datarow>

<CALDAY>20100218</CALDAY>

<PLANT>201</PLANT>

<ZSTR_PLANT>2345.00;/ZSTR_PLANT>

</Datarow>

<Footer>

<FileName>test0001</FileName>

File content conversion:

Datarow.endSeparator ='nl'

Datarow.fieldseparator = ,

Footer.fieldfixedLenghts =0

Footer.fieldlengthTooShortHandling= Cut

Please suggest me anything to change.

Advanced Thanks

Sam

</Footer>

</ns0:MT_google>

Former Member
0 Kudos

Hi Sam,

I see few typos in your content conversion parameters. Can you please put like this:

Recordset Structure : Datarow,Footer

Datarow.endSeparator='nl'

Datarow.fieldSeparator=,

Footer.fieldFixedLengths=0

Footer.fixedLengthTooShortHandling=Cut

Give a try with this and let us know.

Regards,

---Satish

Former Member
0 Kudos

Hi Satish,

Got it . Answered.

Thank you very much.

Sam

Answers (0)