on 10-03-2005 9:43 AM
Hello
I have an xml file which is in this format.
<?xml version="1.0" encoding="UTF-8"?>
<ns0:OUTPUT_ITALY_FORMAT_TYPE xmlns:ns0="urn:sli-payment-files:prototype">
<FEBRITRH>
<Filler/>
<RH/>
<ABI_Code/>
<SIA_Code>65318</SIA_Code>
<Creation_Date/>
<File_Identifier/>
<Filler1/>
<Application_Center/>
</FEBRITRH>
<FEBRIT61>
<Filler/>
<SixtyOne/>
<Accnt_Number>0000001</Accnt_Number>
<Filler1/>
<Blank/>
<Number/>
<Description/>
<Accnt_Code/>
<Bank_DIgit/>
<ABI_Code>06230</ABI_Code>
<Bank_Number>01653</Bank_Number>
<Bank_accnt>000043185249</Bank_accnt>
<Currency_code>EUR</Currency_code>
<Accnt_date>030204</Accnt_date>
<Constant/>
<Amnt/>
<Filler2/>
<FEBRIT62>
<Filler/>
<Constant/>
<Accnt_number>0000001</Accnt_number>
<Record_number>1</Record_number>
<Value_date>040204</Value_date>
<Posting_Date>030204</Posting_Date>
<Constant1>C</Constant1>
<Amnt>0000000000471.58</Amnt>
<Transaction_Code>Z2</Transaction_Code>
<Bank_Code>Z1</Bank_Code>
<Blank/>
<Reference_Number>2535394</Reference_Number>
<Reference>86</Reference>
<Additional_reference>VERS.ASS.IST./SU PIAZZA/CIRCOLARI/</Additional_reference>
</FEBRIT62>
<FEBRIT63>
<Filler/>
<Constant/>
<Accnt_Number/>
<Record_Number/>
<Text>POSTALI/TURIST</Text>
</FEBRIT63>
</FEBRIT61>
<FEBRIT64>
<Filler/>
<Constant/>
<Accnt_Number/>
<Currency_code/>
<Accntg_Date/>
<Constant1>C</Constant1>
<Amnt>0000000000471.58</Amnt>
<Constant2/>
<Cash_balance/>
<Filler1/>
<Balance/>
</FEBRIT64>
<FEBRITEF>
<FEBRITEF_1/>
<FEBRITEF_2/>
<FEBRITEF_3/>
<FEBRITEF_4/>
<FEBRITEF_5/>
<FEBRITEF_6/>
<FEBRITEF_7/>
<FEBRITEF_8/>
<FEBRITEF_9/>
<FEBRITEF_10/>
<FEBRITEF_11/>
<FEBRITEF_12/>
</FEBRITEF>
</ns0:OUTPUT_ITALY_FORMAT_TYPE>
Now i need to convert the above file into a text file when i get the o/p in xml format. I have tried using file content conversion but i am not able to get the solution right. Could anyone let me know as to how should i specify the recordset structure parameters if i need a comma between the fields in each of the structures.Also if u could let me know the other important parameters it could be of great help.
Thanks and Regards
Sharat
Hi Sharat,
Your File format is like
Source Message Type
| - FEBRITRH
| - | - field1..
| - | - field2.. etc
| - FEBRIT61
| - | - field1..
| - | - field2.. etc
| - FEBRIT64
| - | - field1..
| - | - field2.. etc
| - FEBRITEF
| - | - field1..
| - | - field2.. etc
Create a Target Message Type like
Target Message Type
| - Recordset
| - | - FEBRITRH
| - | - | - field1..
| - | - | - field2.. etc
| - | - FEBRIT61
| - | - | - field1..
| - | - | - field2.. etc
| - | - FEBRIT64
| - | - | - field1..
| - | - | - field2.. etc
| - | - FEBRITEF
| - | - | - field1..
| - | - | - field2.. etc
Do all your mappings and
Define a Receiver File Adapter with Following Configuration
<b>Message Protocol</b> File Content Conversion
<b>Content Conversion Parameter</b>
<b>Recordset Structure</b> Recordset, FEBRITRH, FEBRIT61, FEBRIT64, FEBRITEF
Name value pair would be
Recordset.endSeparator nl
FEBRITRH.fieldNames field1,field2
FEBRITRH.fieldSeparator - , (or | )
FEBRIT61.fieldNames field1,field2
FEBRIT61.fieldSeparator - , (or | )
FEBRIT64.fieldNames field1,field2
FEBRIT64.fieldSeparator - , (or | )
FEBRITEF.fieldNames field1,field2
FEBRITEF.fieldSeparator - , (or | )
Hope this Helps,
Vijay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sharat,
I am not sure what do you mean by two sections.
are you calling "FEBRITRH" as section ??
If that is so, you can make the settings like
Target Message Type
| - Recordset
| - | - SECTION1
| - | - | - field1..
| - | - | - field2.. etc
| - | - SECTION2
| - | - | - field1..
| - | - | - field2.. etc
Do your Mapping accordingly.
and make the changes in Receiver adapter as
Recordset Structure Recordset,SECTION1,SECTION2
Name value pair would be
Recordset.endSeparator nl
SECTION1.fieldNames field1,field2
SECTION1.fieldSeparator - , (or | )
SECTION2.fieldNames field1,field2
SECTION2.fieldSeparator - , (or | )
Regards,
Vijay
Hello Vijay
My target interface looks something like this
INPUT_ITALY_FORMAT_TYPE
AUSZUG
BANK
DEL01
KTONR
UMSATZ
VALUT
DEL01
PRIMA
DEL02
So will the solution that you have mentioned work in the above case. So as i understand i will have the following parameters being declared:
Recordset Structure-INPUT_ITALY_FORMAT_TYPE,AUSZUG,UMSATZ
Name Value pair would be
INPUT_ITALY_FORMAT_TYPE.endSeparator-'nl'
AUSZUG.fieldNames-BANK,DEL01,KTONR
AUSZUG.fieldSeparator-,
UMSATZ.fieldNames-VALUT,DEL01,PRIMA,DEL02
UMSATZ.fieldSeparator-,
Just let me know if the above declarations are fine. If so I can proceed further. Looking forward to ur reply....
Thanks and Regards
Sharat
Hi Sharat,
check this link (Converting File Content in the Receiver Adapter)
http://help.sap.com/saphelp_nw04/helpdata/en/0b/9a50465ccf84479e39a6d50c90fb3f/frameset.htm
check the how to guide for jms content conversion in the below link (you should have market place UID), you can use the same modules for content conversion for file adapter as well. (How To Use the Content Conversion Module in JMS Adapter )
https://websmp206.sap-ag.de/~form/sapnet?_SHORTKEY=01100035870000582377&;
Hope this helps to fix your problem
Regards
Vishnu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.