cancel
Showing results for 
Search instead for 
Did you mean: 

File content Conversion Receiver side

Former Member
0 Kudos

Hi Exports,

this interface is from idoc to third part flat file

Target structure is

<?xml version="1.0" encoding="UTF-8"?>

<Test>

<test1>

<Trnnam>aaa</Trnnam>

<Trnver>bbb</Trnver>

<WHSE_ID/>

<test2>

<Segnam>SUPPLIER</Segnam>

<TrnTyp>A</TrnTyp>

</test2>

</test1>

</SUPP_INB_IFD>

Out put file should be like this

<b>aaa|bbb|ccc||<a>SUPPLIER|A</b>

What i have to give the perameters in between the two segments differenciate like this <a>

Could you please provide me flat file perameters.

Advanced thanks

Ramidi s

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

.endSeparator =||(double pipe)

ofcourse you do need other parameters too like fieldSeparator

Thanx

Aamir

Message was edited by:

Aamir Suhail

Former Member
0 Kudos

Ramidi,

this seems to a nested structure. did you manage to get the file using content conversion

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

Use

recordsetname.fieldSeparator=|

recordsetname.endSeparator = what ever you want if you want newline use 'nl'

Former Member
0 Kudos

Hi,

You have a nested structure..which can cause trouble.

Cant you have a structure like this:

<Test>

+<test1>

++<Trnnam>aaa</Trnnam>

++ <Trnver>bbb</Trnver>

++</WHSE_ID>

+<test1/>

+<test2>

++<Segnam>SUPPLIER<Segnam/>

++<TrnTyp>A<TrnTyp/>

+ <test2/>

+</SUPP_INB_IFD>

<Test/>

You can try out content conversion for this.

For the content conversion parameters you can check out in search.

If any problem in this let us know.

Regards,

Manju

Former Member
0 Kudos

Hi Manju,

that's correct. my structure same as you mentioned. How do i do the content conversion for this. There is two segments seperated by delimeter like & i need fields seperated by |.

<Test>

+<test1>

++<Trnnam>aaa</Trnnam>

++ <Trnver>bbb</Trnver>

++</WHSE_ID>

+<test1/>

+<test2>

++<Segnam>SUPPLIER<Segnam/>

++<TrnTyp>A<TrnTyp/>

+ <test2/>

<Test/>

Target file should be like this.

aaa|bbb||&SUPPLIER|A

i need like this. Could you please help me.

i need to differenciate the segments with & symbol

Thanks

Ramidi S

Former Member
0 Kudos

hi ramidi,

in recordset structure give test1 and test2 and set parameters for test1 and test2 like test1.fieldSeparator, test1.endSeparator. similarly for test2.

refer this:

/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion

regards,

latika.

Former Member
0 Kudos

Ramidi,

Recordset Structure:Test,test1,test2

Parameters:

Test.fieldNames test1,test2

test1.fieldNames Trnnam,Trnver

test1.fieldSeparator |

test1.endSeparator '&'

Write in the similar fashion for test2.

Be careful about the Case.The parameters are case sensitive.

Former Member
0 Kudos

hi,

for this you can try like this

<b>RecodsetName:: test

recordserStructure:: test1,test2,*</b>

in next step

<b>test1.fieldSeparator :: ,( or watever u want)

test1.endSeparator :: 'nl'( or watever u want)

test2.fieldSeparator :: ,( or watever u want)

test2.endSeparator :: 'nl'( or watever u want)</b>

hope this will help

regards

HONEY

Former Member
0 Kudos

Hi Manju,

Thank you for your replay. I given the parameters which you given. but it's not coming & in between the segments. any idea for this.

Test.fieldNames test1,test2

test1.fieldNames Trnnam,Trnver

test1.fieldSeparator |

<b>test1.endSeparator '&'</b> (this is not working)

test2.fieldNames Field1,Field2

test2.fieldSeparator |

test2.endSeparator 'nl'

Last end separator is working but segments test1.endSeparator '&' not working.

Any suggestions please

Former Member
0 Kudos

i guess it won't work due to the message type you have defined.

element <Test> and <test1> have parent-child relationship meaning they will occur together,but <test1> and <test2> have a child-child relationship meaning they will occur separately,i guess if you specify test1.endSeparator ='nl' then it should work but will give <test2> in a different line.

to get all the elements in one line you need have a parent-child relationship and not a child-child relationship

Thanx

Aamir

Message was edited by:

Aamir Suhail

Former Member
0 Kudos

Hi Ramidi,

Can you just try putting ';' (or any other character) as the endSeparator.

I'm not very sure but have heard that there are problems with having '&'....

As Aamir has said it would work if 'nl' is put.If you are ok with having new line as the separator proceed with this.

Regards,

Manju

Message was edited by:

Manjusha Nair