cancel
Showing results for 
Search instead for 
Did you mean: 

FCC using MessageTransformBean

itabhishek9
Participant
0 Kudos

Hi SDNites,

I am aware of FCC functionality which is provided in FTP adapter,

1. But can we test FCC in FTP using MessagTransformBean.

2. If yes, then the message protocol that needs to be selected here should be File and Module should be provided as localejbs/AF_Modules/MessageTransformBean.

3. I tried the above and have set the relevant parameters but not able to read the CSV file which is spearted by Semi Colon. Parameters paased are,

Transform.Class                  com.sap.aii.messaging.adapter.Conversion

Transform.ContentType        text/xml;charset=utf-8

xml.conversionType             SimplePlain2XML

xml.documentName             <My Outbound Msg. type>

xml.documentNamespace    <IR namespace>

xml.endSeparator                'nl'

xml.fieldNames                   <Field1>,<Field2>,<Field3>

xml.fieldSeparator               '0x1b'

xml.processFieldNames      fromConfiguration

xml.recordSetName            RecordSet

xml.recordSetStructure       Node1,* (Here Node1 is the node below Recordset under which all fields are present)

Regards,

Abhi

Accepted Solutions (1)

Accepted Solutions (1)

itabhishek9
Participant
0 Kudos

- An imporatnt thing to notice here is that when I replace semi colon with Comma, it worked fine. But when I replaced back to Semi Colon, my communictaion channel mo nitoring is showing "More elements in file CSV structure than field names specified'. And it has also mentioned then line no. as 5 which is my 5th and last record in my test file. Note : While maitaining file I have pressed enter in the last record.

@Hareesh - Yes you are correct but even after changing the same, I am getting the problem as mentioned above.

Regards,

Abhi

former_member184720
Active Contributor
0 Kudos

Did you try adding "xml.additionalLastFields" ignore  to the configuration?

Answers (2)

Answers (2)

itabhishek9
Participant
0 Kudos

Great Hareesh. It worked after applying the above mentioned parameter.

I would like to inform one thing that before applying what you said above I deleted 5th line from my test file and it also worked.

Can you please let me know the significance of the above parameter.

Regards,

Abhishek

former_member184720
Active Contributor
0 Kudos

There might be additional spaces or new line in your old file.

Above paramter ignores if there is any additional data in your input file other than what is mentioned in your configuration.

If you send a file without any additional spaces/newline then your file should process without that parameter.

former_member184720
Active Contributor
0 Kudos

I don't think recorset name and recordSetStructure  are part of simple plain 2 xml.

As you just one strcture i.e. node1 you can adjust the configuration as explained in the below blog.

Remove them and add below entry as you just have one node

xml.structureTitle Node1

if you have multiple them you should go for "StructPlain2XML"

itabhishek9
Participant
0 Kudos

Thanks Haressh for the above response.

But the same has not resolved my problem. I have used all the relevant paramters but still in my payload I can see that the fields are not separated by ; and it is coming as 1 string only.

Field1;Field2;Field3.

While the expected output is

<Field1> value </Field1>

<Field2> value </Field2>

<Field3> value </Field3>

Regards,

Abhi


nabendu_sen
Active Contributor
0 Kudos

Hi Abhi,

Have you tried "fieldSeparator          |     ';' " ?

Regards,

Nabendu.

former_member184720
Active Contributor
0 Kudos

That is because the field separator value that you provided is wrong. it should be 0x3b ??

itabhishek9
Participant
0 Kudos

Hi Nabendu,

Yes I did but with no help.

xml.fieldSeparator - ';'    (Semi Colon between single quotes)

Regards,

Abhi


nabendu_sen
Active Contributor
0 Kudos

Then remove Single Quotes and give a try with ONLY ;