cancel
Showing results for 
Search instead for 
Did you mean: 

csv to rfc

Former Member
0 Kudos

hi all,

I have tried the file to file scenario and its working fine. Now i'm trying the file to csv scenario. In the same file to file scenario I have done changes in the receiver communication channel like file content conversion. In the datatype i have only one element with two sub elements, is that fine or do i need to change the receiving structure with more sub elements.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

Do the same as Jai says..

Your scenario is csv..these blog might help you...

<u>/people/venkat.donela/blog/2005/06/08/how-to-send-a-flat-file-with-various-field-lengths-and-variable-substructures-to-xi-30

<u>/people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem

Cheers!

Samarjit

Message was edited by:

Samarjit Dey

Former Member
0 Kudos

Arunkumar,

If you could give the XML output after mapping, we can guide you better.

P.S: Your subject line and thread discusses different issues.Try to avoid this.

Regards,

Jai Shankar

Former Member
0 Kudos

hi jai ,

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

<ns0:messagetype xmlns:ns0="http:
ftptoftp">

<rollnumber>101</rollnumber>

<name>arun</name>

</ns0:messagetype>

This is the xml code that is created.

Former Member
0 Kudos

Arun,

Change your data type slightly. Add the tag <Employee>

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

<ns0:messagetype xmlns:ns0="http:
ftptoftp">

<b><Employee></b>

<rollnumber>101</rollnumber>

<name>arun</name>

<b></Employee></b>

</ns0:messagetype>

FCC parameters

Recordset structure : Employee

Employee.filedSeparator ,

Employee.endSeparator 'nl'

Regards,

Jai Shanakr

Former Member
0 Kudos

Jai,

Should i do it in the receiving structure? if so, is thr any mapping required?

Former Member
0 Kudos

>>Should i do it in the receiving structure?

Yes.

>>if so, is thr any mapping required?

Yes. Map the values directly from source to target fields.

Regards,

Jai Shankar

Former Member
0 Kudos

Jai,

Can you please explain me what is the significance of adding the Employee tag?

is it mandatory in file to csv case that the receiving structure should have a extra element than the sending structure

Regards

Arun

Former Member
0 Kudos

>>is it mandatory in file to csv case that the receiving structure should have a extra element than the sending structure

No. To perform File Content Conversion, you need to have a structure that encloses the fields. In your case, the fields are rollno and another field. It does not have any enclosing structure. So I added a structure to enclose this.

The name Employee is arbitary. You can have any name.

Regards,

Jai Shankar

Former Member
0 Kudos

I am just trying out this scenario..will let you know in sometime

Former Member
0 Kudos

Hi-

In the XML structure do as Jai has mentioned.then in the mapping also u have to change according to this XML file ie.datatype and Mapping.Then in the receiver CC change the File Content conversion parameters.

Check this thread for FCC parameters

Former Member
0 Kudos

hi jai,

i created a new scenario right from the design part. The file is getting picked up from the ftp server but am not getting the csv file back. When i take a look in the TCODE sxmb_moni - it says successfully processed.is thr any other way to find out wat's wrong?

Regards

Arun

Former Member
0 Kudos

Use the coomunication channel monitoring tool in RWB.

RWB>Component monitoring>Adapter Engine -->Coomuniation channel monitoring.

Choose your receiver communication channel and check for error msg.

Regards,

Jai Shankar

Former Member
0 Kudos

hi jai,

am not able to login to RWB.But when i change the receiver comm channel as normal file ( without file content conversion ) - it works fine. so, must be something in the conversion i guess...suggestions please

Regards

Arun

Former Member
0 Kudos

>>must be something in the conversion i guess...suggestions please

You are correct. But the only place that shows the error log related to FCC is RWB.

Fine. Let us give a try with out error msg. Give us the XML after mapping(copy it from SXMB_MONI) and the FCC parameters you have used.

Regards,

Jai Shankar

Former Member
0 Kudos

FCC parameters :

dt_filetocsv_receiver.fieldseparator ,

dt_filetocsv_receiver.endseparator 'nl'

dt_filetocsv_receiver.addheaderline 1

dt_filetocsv_receiver - this is the receiver datatype

xml file from sxmb_moni :

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

- <ns0:MT_filetocsv_sender xmlns:ns0="http://arun_filetocsv">

<ROLLNO>101</ROLLNO>

<NAME>arun</NAME>

<ADDRESS>asdf</ADDRESS>

</ns0:MT_filetocsv_sender>

Former Member
0 Kudos

When I test this xml message in test configuration it fails in interface mapping...

Former Member
0 Kudos

hi jai.

I finally figured out the problem in my scenario. In the content conversion parameters i didn't use the 'fieldSepararor' as mentioned here, I used it as follows 'fieldseparator'. The s was in small letters...

Anyway thx for your suggestions and patience.