2010 Nov 09 5:28 PM
Hi.
I have an internal table with 83 columns. And I am using the function SAP_CONVERT_TO_CSV_FORMAT to convert it to the CSV format. The problem is that in the excel file it only appears 26 columns have anyone faced this problem?
2010 Nov 09 6:20 PM
Hi, other thing that you can do is, create a internal table with a simple field with 2000 characters length. Fill this internal table with all the columns that you have separated by comma ",". Use the function to download the internal table "GUI_DOWNLOAD" and specify the file with CSV extesion.
When you open the file, it will be open with Excel.
Let me know is this helped you.
Regards
Jesus Martinez
2010 Nov 09 5:39 PM
2010 Nov 09 6:07 PM
Are you using the semi-colon as your delimiter when opening the text file with Excel?
2010 Nov 09 6:20 PM
Hi, other thing that you can do is, create a internal table with a simple field with 2000 characters length. Fill this internal table with all the columns that you have separated by comma ",". Use the function to download the internal table "GUI_DOWNLOAD" and specify the file with CSV extesion.
When you open the file, it will be open with Excel.
Let me know is this helped you.
Regards
Jesus Martinez
2010 Nov 09 6:26 PM
GUI_DOWNLOAD supports transfers up to 1024 bytes, not 2000...
2010 Nov 09 6:23 PM
Why don't you try with the function Download
DATA: ZM_FICHERO(128),
ZM_TIPO(3),
ZM_TIPRES(3).
CALL FUNCTION 'DOWNLOAD'
EXPORTING CODEPAGE = SPACE
FILENAME = 'C:\'
FILETYPE = 'DAT'
ITEM = 'REPORTE'
IMPORTING ACT_FILENAME = ZM_FICHERO ' --> Name of file to be saved
ACT_FILETYPE = ZM_TIPRES
FILESIZE = ZM_TAMANO '--> size
TABLES DATA_TAB = TI_DATA '--> ITAB
EXCEPTIONS INVALID_FILESIZE = 1
INVALID_TABLA_WIDTH = 2
INVALID_TYPE = 3.
2010 Nov 09 11:02 PM
Hi,
why you do not export data in native excel?
try to read these blogs
[abap2xlsx - Generate your professional Excel spreadsheet from ABAP|http://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/20046] [original link is broken] [original link is broken] [original link is broken];
[xlsx2abap - Read and edit your Excel files from ABAP|http://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/20791] [original link is broken] [original link is broken] [original link is broken];
Code of this SCN Community project is shared on [Code Exchange|https://cw.sdn.sap.com/cw/groups/abap2xlsx]
Regards
Ivan
2010 Nov 10 4:06 AM
hi,
in that case you create a program in se38 then define your structure or table, define itab ,then use
loop at itab.
call function module download.
end loop.
in download function module uncomment exporting, file name, file type and infront it_tab=itab.
you get your all data.
use filetype as dat format
Sulabh
Edited by: sulabh agrawal on Nov 10, 2010 5:07 AM
2010 Nov 10 9:55 AM
Hi.
I am using the semicolon separator. However I cannot use the function guidownload or the download one, because I need to export this excel as an attach in an email. I cannot export in native excel since it was requested to send it in CSV format.
2010 Nov 10 10:44 AM
Thank you Jesús Martinez, your answer solved my problem. But I had to put a semi colon ';' intead of the coma.
Best regards,
2010 Nov 16 9:30 PM
You are welcome, we are here to help us. Any other question, please let me know.
Have a great day!
2024 Oct 04 1:14 PM
I have another issue with the FM SAP_CONVERT_TO_CSV_FORMAT. Everything works fine with this when we pass internal table as input but when we have uuid fields in the internal table, the output values do not appear properly. It comes as #㻿必#쪞嗺賻 . Can anyone help here?