Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

regarding about bdc

Former Member
0 Likes
572

Hi expeerts,

I have data in four spread sheet for four tcode updation.give me some idea about this.

Thanks

1 ACCEPTED SOLUTION
Read only

former_member156446
Active Contributor
0 Likes
553

Hi

this will be the code to read the data from excel file

CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
       EXPORTING
            filename                = filename
            i_begin_col             = begcol
            i_begin_row             = begrow
            i_end_col               = endcol
            i_end_row               = endrow
       TABLES
            intern                  = intern
       EXCEPTIONS
            inconsistent_parameters = 1
            upload_ole              = 2
            OTHERS                  = 3.

  IF sy-subrc <> 0.
    WRITE:/ 'Upload Error ', SY-SUBRC.
  ENDIF. 

4 REPLIES 4
Read only

Former Member
0 Likes
553

Hi,

If you want to do this in one session ..You can do it by writing a Zprogram and reading your Excel into four different Internal Tables.

You need to do the Four Recordings also and you have to use four different Calls for the BDC_INSERT FM so as to update all in a Single Session.

Read only

Former Member
0 Likes
553

Use session method for that.

create one session and

call the bdc_insert once for each of the transactions.

Read only

0 Likes
553

Thank you

Read only

former_member156446
Active Contributor
0 Likes
554

Hi

this will be the code to read the data from excel file

CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
       EXPORTING
            filename                = filename
            i_begin_col             = begcol
            i_begin_row             = begrow
            i_end_col               = endcol
            i_end_row               = endrow
       TABLES
            intern                  = intern
       EXCEPTIONS
            inconsistent_parameters = 1
            upload_ole              = 2
            OTHERS                  = 3.

  IF sy-subrc <> 0.
    WRITE:/ 'Upload Error ', SY-SUBRC.
  ENDIF.