on 04-25-2007 2:21 PM
Hi experts,
i have some sample data that is in txt format,i have to send this data to SAP system using File adapter using FILECONTENT Conversion.
plz help me how to write the code.
This is the sample code...and this all data have to come in a single output line
HEADER 200704050203328593893099203
STOCKDIFF 00000000000014008770380347UA 0000000864.000
STOCKDIFF 00000000000014009770460347UA 0000003666.000
STOCKDIFF 00000000000014009761020347CSS0000000001.000
STOCKDIFF 00000000000014009763460347CSS0000000005.000
STOCKDIFF 00000000000014009861880347TA 0000000128.000
STOCKDIFF 00000000000014009870210347TA 0000000640.000
FOOTER 005317
HEADER 200704050203328593893099203
STOCKDIFF 00000000000014008770380347UA 0000000864.000
STOCKDIFF 00000000000014009770460347UA 0000003666.000
STOCKDIFF 00000000000014009761020347CSS0000000001.000
STOCKDIFF 00000000000014009763460347CSS0000000005.000
STOCKDIFF 00000000000014009861880347TA 0000000128.000
STOCKDIFF 00000000000014009870210347TA 0000000640.000
FOOTER 005317
FILES -
0....UN
HEADER GROUP -
1..1
RECORD_TYPE
CREATION DATE
CURRENT TIME
GLN_CODE
DETAIL GROUP----
0....UN
RECORD_TYPE
MATERIAL NO
BATCH_CODE
QUALITY
QUANTITY
BATCH_STATUS
FOOTERGROUP----
1....1
RECORD_TYPE
RECORD_COUNT
Regards,
phani
HI,
Document Name : message type name
docuemntnamespace : give namesapce
Record set name : FILES
Recordset structure : header,1,detail,*,footer,1
header.fieldNames : give the header fields
header.fieldSeparator :,
header.endseparator:'nl'
header.processFieldNames : from Configuration
repeat the above 4 lines for detail,footer .. you just replace header with detail or footer
see also the below link
/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter
Regards
Chilla
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
handle this is proxy. the code wud normally look like below, not the exact one
loop at itab into witab.
concatenate STROUT witab into STROUT.
clear witab.
endloop.
but here the potential problem might be the number of characters STROUT could hold. I believe for string declaration it can hold upto 255 characters
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.