Hello,
I have a requirement to export a couple of files that need to be in a fixed length format.
I've tried opening the dataset and writing the records passing the column that the records should appear:
WRITE /, field1, 10 field2, etc...
I've also tried to do it through SAP_CONVERT_TO_CSV_FORMAT and the text version as well.
Is there a predefined function that will allow me to export as fixed length?
Thank you in advance
Function Modules
http://www.erpgenie.com/abap/functions.htm
http://www.sapdevelopment.co.uk/fmodules/fmssap.htm
http://www.erpgenie.com/abap/index.htm
http://www.geocities.com/victorav15/sapr3/abapfun.html
Rewards if useful..........
Minal
Hi Jeff,
Following is the code to do the same:
DATA: file TYPE string VALUE `flights.dat`, wa TYPE spfli. FIELD-SYMBOLS TYPE x. OPEN DATASET file FOR OUTPUT IN BINARY MODE. SELECT * FROM spfli INTO wa. ASSIGN wa TO CASTING. TRANSFER TO file. * TRANSFER LENGTH 200 to file. ENDSELECT. CLOSE DATASET file.
Best regards,
Prashant
Add a comment