on 08-29-2006 9:48 PM
Hi
Does any body help me for mapping between header and line items in BAPI..
my scenario is filerfcmail(wokflow)!
File is CSV based :
(ex: 001150,,1123,JERM,08122006,,,
,,,ANN,,01082006,
If you look at example csv file , there is some fields mixed with header and line items. But in RFC header can be 1 to 1 and line item should be 0 to Unbound.
Now my problem is if I sent above example csv file as source :
The payload coming like this(sxmb_moni) :
</HEADERDATA>
- <GLACCOUNTDATA>
- <item>
<COSTCENTER />
<PROFIT_CTR />
</item>
- <item>
<GL_ACCOUNT>738100</GL_ACCOUNT>
<ITEM_AMOUNT>60000</ITEM_AMOUNT>
<COMP_CODE>001150</COMP_CODE>
<ITEM_TEXT>*777-8030-861</ITEM_TEXT>
<COSTCENTER>7320</COSTCENTER>
<PROFIT_CTR>7320</PROFIT_CTR>
<ALLOC_NMBR />
</item>
- <item>
<GL_ACCOUNT>738100</GL_ACCOUNT>
<ITEM_AMOUNT>40000</ITEM_AMOUNT>
<COMP_CODE>001151</COMP_CODE>
<ITEM_TEXT>*777-8030-861</ITEM_TEXT>
<COSTCENTER>6010</COSTCENTER>
<PROFIT_CTR>6010</PROFIT_CTR>
<ALLOC_NMBR />
</item>
<item />
</GLACCOUNTDATA>
You can find there is one more item coming after headerdata with null values. It means map reading first line and one by one , if any field found in rows which belogs to GLAccount(Line item), then it writing one more item after headerdata with that fields only.
Remainig GLAccount data coming as per map after the item .
Can you tell me how to avoid extra line items.
Thanks,
Sankar
Hi,
You can check if element <GL_ACCOUNT> exists.
regards,
wojtek
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, It exist..
I cross checked ..with out givig fileds and giving some fields...its writing another items in after headerdata tag.
hope you understand , what my problem..
See: GLACCOUNTDATA under subnode
item is 0 to unbound in BAPI side, because of this its reading all rows , and if find any field which belongs to GLAccount , then it writing another item tag after headerr data.
Thnaks,
Sankar
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
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.