Skip to Content
author's profile photo Former Member
Former Member

upload an excel file into a table

Good Morning:

I have to upload the contents of an excel file into a table. Someone knows how to do it?

Thanks a lot.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

5 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2005 at 10:04 AM

    Hi,

    See this sample code.

    ***************

    At selection-screen on value-request for p_file.

    call function 'F4_FILENAME'

    exporting

    field_name = 'p_file'

    importing

    file_name = p_file.

    clear itab.

    call function 'WS_UPLOAD'

    exporting

    codepage = ' '

    filename = p_file

    filetype = 'DAT'

    tables

    data_tab = itab

    exceptions

    conversion_error = 1

    file_open_error = 2

    file_read_error = 3

    invalid_type = 4

    no_batch = 5

    unknown_error = 6

    invalid_table_width = 7

    gui_refuse_filetransfer = 8

    customer_error = 9

    others = 10.

    ************************

    Here you need to save your Excel file as a 'DAT' file.

    I hope this will help you.

    CHEERS

    Message was edited by: Deepak333 k

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2005 at 10:09 AM

    Hi Jorge,

    I answered a similar type of question just look into this

    it may help you.

    import-excel-file-into-abap

    reward points for helpfull answers and close the thread if your question is solved.

    regards,

    venu.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2005 at 10:13 AM

    Hi,

    You can find a sample code here:

    http://www.sapdevelopment.co.uk/file/file_upexcel2.htm

    Best Regards,

    Anjali

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2005 at 10:13 AM
    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2005 at 10:52 AM

    Hi Jorge,

    U can use the FM 'ALSM_EXCEL_TO_INTERNAL_TABLE' to upload data from excel file to internal table.

    Regards,

    Phani

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.