Skip to Content
avatar image
Former Member

Are there any BAPIs for creating,updating & deleting quota

Are there any BAPIs for creating,updating & deleting quota for which data is maintained in an excel file.

Please suggest if there is any solution

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Jul 02, 2017 at 11:36 AM

    A possible solution will have 2 steps:

    1) Read an Excel-file into internal table

    2) Create a Quotation

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

    * Read an Excel-file into an internal table *

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

    DATA: p_file TYPE rlgrap-filename DEFAULT 'Z:\quotation_data.xls'.

    CALL FUNCTION 'UPLOAD_XLS_FILE_2_ITAB'
    EXPORTING
    i_filename = p_file
    TABLES
    e_itab = gt_itab_string
    EXCEPTIONS
    file_error = 1
    OTHERS = 2.

    IF sy-subrc <> 0.
    CASE sy-subrc.
    WHEN 1. WRITE:/ 'FILE_READ_ERROR'.
    WHEN 2. WRITE:/ 'FILE_UPLOAD_ERROR'.
    ENDCASE.
    RETURN.
    ENDIF.

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

    * Create a Quotation *

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

    Check:

    BAPI_QUOTATION_CREATEFROMDATA

    Best regards

    Add comment
    10|10000 characters needed characters exceeded