Reg: bapi and bdc

Hi Friends,
I am trying to use a transaction IS01 in crm  in which i need to upload the long text, but when i am recording it , the particular field (long text) for which i need to give input is not appearing, since it is not a  screen batch input field, so is there any bapi available for it to use to transfer the longtext in the transaction IS01 or hw can i record it in BDC while recording and hw can i pass the long text to that particular screen in transaction
Venki..

Hi Friends,
I am trying to use a transaction IS01 in crm  in which i need to upload the long text, but when i am recording it , the particular field (long text) for which i need to give input is not appearing, since it is not a  screen batch input field, so is there any bapi available for it to use to transfer the longtext in the transaction IS01 or hw can i record it in BDC while recording and hw can i pass the long text to that particular screen in transaction
Venki..

Similar Messages

  • What is BAPI?How to create a BAPI? Difference b/w BAPI and BDC

    Hi all,
    Can some one help me regarding...
    What is an BAPI?where it is used?
    How to create a BAPI?
    What is the difference between BAPI and BDC Program?
    Iam in Initial stage regarding BAPI concept.
    Please respond me soon.
    Thanks,
    Lee

    HI,
    Here it is:
    BAPI Programming Guide
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
    BAPI User Guide
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
    http://techrepublic.com.com/5100-6329-1051160.html#
    http://www.sap-img.com/bapi.htm
    http://www.sap-img.com/abap/bapi-conventions.htm
    http://www.sappoint.com/abap/bapiintro.pdf
    http://ifr.sap.com/catalog/query.asp
    STEP BY STEP for BAPI
    http://sap-img.com/abap/bapi-step-by-step-guidance.htm
    <b>DIFFERENCE between BAPI and BDC</b>
    BDC is traditional way of coding the transactions for uploading the legacy data, Sap is changing all transactions to Object oriented programming. Since BAPI is Object based and supports all the new transactions it is preffered over BDC. More over BAPI's process data faster than BDC.
    BAPI is a SAP-supplied function module with a defined interface, which allows you to interact with various business objects. SAP guarantees the integrity of your database for anything updated using a BAPI. BDC is a method of driving screens programatically, for updating SAP data. BAPIs are generally faster than BDCs.
    A BAPI is faster because it is updating the DB "directly". Whereas BDC with call
    transaction goes through the whole screen sequence like any user would do, simply put, fills screens.
    However - there is not always a BAPI for a particular transaction and not all functions that are performed by a transaction can be done by a BAPI. BDCs produce error sessions which can be processed by the user, while BAPIs don't.
    First choose the BAPI ,if there is no BAPI go for BDC.
    why BAPI first not BDC.
    SAP comes up with Change in Version, so each and every time they will change the screens/number etc.
    so you have to change your BDC programs accordingly.
    and also Most of the Latest versions transactions are Enjoy Transaction. they will not support BDC's in Background.
    But Using BAPI's No such disadvantages.
    A BAPI is faster because it is updating the DB "directly" through ABAP code.
    A BDC with call transaction goes through the whole screen sequence like any user would do, simply put, it is filling screens.
    Actually it depends on your requirement but BAPI is more effective as it is standard function module to update SAP databases rather than BDC.
    using bdc over bapi has advantages and also disadvantages
    advantages:
    1. using bdc we can upload data into database tables using 2 ways
    1. foreground -
    means that user interaction is there for each and every record.
    2. back ground -
    no user interaction and tasks are done automatically.
    using these two options is one of the greatest advantage over bapi.
    2. in bdc call transaction method we can control the display of screen resolution which is not possible with bapi's
    3. bdc is generally used for transferring of large amount of data than bapi's
    4.session method of bdc allows us to place data directly in application server and then finally transfered into sap database tables
    disadvantages:
    1.bdc is only used for sap to sap system data transferring
    2. bapis's generally works more faster than bdc's
    3. using bapis we can connect to remote systems and also to non sap systems.
    if useful reward some points.
    A BAPI is a method of a SAP Business Object. BAPI enables SAP and third party applications to interact and integrate
    with each other at the Business Object / Process level.
    Check this link to know more about BAPI.
    http://www.sapgenie.com/abap/bapi/example.htm
    http://sappoint.com/abap/
    Batch Data Communication (BDC) is the oldest batch interfacing technique that SAP provided since the early versions of R/3. BDC is not a
    typical integration tool, in the sense that, it can be only be used for uploading data into R/3 and so it is not bi-directional.
    BDC works on the principle of simulating user input for transactional screen, via an ABAP program. Typically the input comes in the form
    of a flat file. The ABAP program reads this file and formats the input data screen by screen into an internal table (BDCDATA). The
    transaction is then started using this internal table as the input and executed in the background.
    In ‘Call Transaction’, the transactions are triggered at the time of processing itself and so the ABAP program must do the error handling.
    It can also be used for real-time interfaces and custom error handling & logging features. .
    To know more about BDC,
    check the link.
    http://sappoint.com/abap/
    Main differences are...
    In case of bdc data transfer takes place from flat file into sap system ie the file existing in sap system to sap sytem
    where is bapi's r remotly enabled function modules which are assigned to some business objects n used to transfer the data between different business partners who are using different systems other than sap.
    not only that...
    when you plan to upgrade your system version then bdc willnot support those upgradations where as bapi's will support.
    <b><REMOVED BY MODERATOR></b>
    Manish
    Message was edited by:
            Alvaro Tejada Galindo

  • PROGRAM WITH BAPI and BDC's

    Hi All,
    I am using a 2 BAPI's and 3 BDC's in a program. I need all these BAPI and BDC's update the tanscations in a single bundled task? that is if any of BAPI or BDC failed the sucessful BAPI/BDC should be rolled back. How can I make it happen? Any sample code will be helpful
    All Suggestion will be rewarded.

    BAPI-step by step procedure
    http://www.sapgenie.com/abap/bapi/example.htm
    list of all BAPI's
    http://www.planetsap.com/LIST_ALL_BAPIs.htm

  • Problem in creating and updating of  material by the use of bapi and bdc

    Hello All,
    I am using bapi (BAPI_MATERIAL_SAVEDATA ) and than bdc to create and update classification data of material.
    I am facing a problem.
    1) firstly I am creating material by the use of bapi and than after creation i want to update classification data for taht perticular material .
    2) To update classification data i am using bdc . while at the time of updating material through bdc system showing me error that material is currently locked by user (my login name ).
    Please suggest what to do.
    Tkank you
    With Regards
    Shantanu Modi

    When u update/create data it takes sometime to commit. So after using BAPI
    give 10 minutes wait in ur program before updating classification data.
    you can write like
    wait up to 20 seconds.
    and update the classification.

  • BAPI AND BDC

    How is BAPI different from call transaction or session

    BAPI is a SAP-supplied function module with a defined interface, which allows you to interact with various business objects. SAP guarantees the integrity of your database for anything updated using a BAPI.
    BAPI enables SAP and third party applications to interact and integrate with each other at the Business Object / Process level.
    Check this link to know more about BAPI.
    http://www.sapgenie.com/abap/bapi/example.htm
    http://sappoint.com/abap/
    BDC is a method of driving screens programatically, for updating SAP data.BDC is not a typical integration tool, in the sense that, it can be only be used for uploading data into R/3 and so it is not bi-directional.
    BDC works on the principle of simulating user input for transactional screen, via an ABAP program. Typically the input comes in the form of a flat file. The ABAP program reads this file and formats the input data screen by screen into an internal table (BDCDATA). The transaction is then started using this internal table as the input and executed in the background.
    It can also be used for real-time interfaces and custom error handling & logging features. .
    To know more about BDC,check the link.
    http://sappoint.com/abap/
    BAPI V/S BDC:
    SAP comes up with Change in Version, so each and every time they will change the screens/number etc.
    so you have to change your BDC programs accordingly.
    and also Most of the Latest versions transactions are Enjoy Transaction. They will not support BDC's in Background.
    But Using BAPI's No such disadvantages.

  • EITHER BAPI OR BDC IS BEST FOR F-02

    Hello Friends,
    Iam doing bdc for f-02 even bapi to but iam stuck in middle. i want to upload data for F-02 using posting keys
    40 and 50.
    iam sending sample code for it can any one rectify and tell me whats wrong with this....
    Iam sending both bapi and bdc code...
    Regards
    Bohra.
    REPORT  ZBDC_TEST no standard page heading line-size 255.
    INCLUDE BDCRECX1.
    PARAMETERS: filename LIKE rlgrap-filename.
    TYPES : BEGIN OF IT_TAB,
            bldat(2),                  " DOC DATE
            blart(2),                  " DOC TYPE
            bukrs(4),                  " COMPANY CODE
            budat(8),                  " POSTING DATE
            waers(5),                  " CURRENCY
            xblnr(16),                 " HEADER REF
            bktxt(50),                 " HEADER TXT
          newbs(2),                  " POSTING KEY
            accnt(16),                 " ACCOUNT
            umskz(1),                  " SPL GENREAL LEDGER
            wrbtr(13),                 " AMOUNT IN FOR CURRENCY
            dmbtr(13),                 " AMOUNT FOR COMPANY CODE INR
            zterm(4),                  " PAYEMENT TERM
            zfbdt(8),                  " BASELINE DATE
            wt_wit(2),                 " WITH TAX CODE
            wt_qs(15),                 " WITH TAX BASE
            wt_qb(15),                 " WITH TAX AMOUNT
            mwskz(2),                  " TAX CODE
            bupla(4),                  " BUSINESS PLACE
          bukrs(4),
            kostl(10),                 " COST CENTER
            acgl_it(12),               " INTERNAL ORDER
            acgl_i(10),                " PROFIT CENTER
          acgl_it(8),               " PERSONAL NO
            zuonr(18),                 " ASSIGNMENT
            xblnr1(16),                                         " REF1
            xblnr2(16),                                         " REF2
            xblnr3(16),                                         " REF3
            sgtxt(50),                 " LINE TEXT
          END OF IT_TAB.
    DATA: IT_TAB1 TYPE TABLE OF IT_TAB.
    DATA: WA_HEAD LIKE LINE OF IT_TAB1.
    data: it_bdcdata like bdcdata occurs 0 with header line.
    data: it_bdcmsgcoll like bdcmsgcoll occurs 0 with header line.
    data: i_error like itab occurs 0 with header line.
    data: i_sucess like itab occurs 0 with header line.
    data: v_flag.
    data: v_msg(200).
    DATA :  w_file1 TYPE string.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR filename.
      CALL FUNCTION 'F4_FILENAME'
        IMPORTING
          file_name = filename.
    START-OF-SELECTION.
      w_file1 = filename.
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename            = w_file1
          filetype            = 'ASC'
          has_field_separator = 'X'
        TABLES
          data_tab            = it_tab1.
    CALL FUNCTION 'BDC_OPEN_GROUP'
    EXPORTING
      CLIENT                    = SY-MANDT
       GROUP                     = 'F-02'
       KEEP                      = 'X'
       USER                      = SY-UNAME.
       CALL FUNCTION 'BDC_INSERT'
        EXPORTING
          TCODE                  = 'F-02'
         TABLES
           DYNPROTAB              = IT_TAB1.
           CALL FUNCTION 'BDC_CLOSE_GROUP'.
    RECORDING PROGRAM FOR F-02
      loop at it_tab1 into wa_head.
        perform bdc_dynpro using 'SAPMF05A' '0100'.
        perform bdc_field using 'BDC_CURSOR'
                                'RF05A-NEWKO'.
        perform bdc_field using 'BDC_OKCODE'
                                '/00'.
        perform bdc_field using 'BKPF-BLDAT'
                                 WA_HEAD-BLDAT.
        perform bdc_field using 'BKPF-BLART'
                                'SA'.
        perform bdc_field using 'BKPF-BUKRS'
                                 WA_HEAD-BUKRS.
        perform bdc_field using 'BKPF-BUDAT'
                                 WA_HEAD-BUDAT.
        perform bdc_field using 'BKPF-MONAT'
                                '3'.
        perform bdc_field using 'BKPF-WAERS'
                                 WA_HEAD-WAERS.
        perform bdc_field using 'BKPF-XBLNR'
                                 WA_HEAD-XBLNR.
        perform bdc_field using 'BKPF-BKTXT'
                                 WA_HEAD-BKTXT.
        perform bdc_field using 'FS006-DOCID'
        perform bdc_field using 'RF05A-NEWBS'
                                 WA_HEAD-NEWBS.
        perform bdc_field using 'RF05A-NEWKO'
                                '100100'.
        perform bdc_dynpro using 'SAPMF05A' '0300'.
        perform bdc_field using 'BDC_CURSOR'
                                'RF05A-NEWKO'.
        perform bdc_field using 'BDC_OKCODE'
                                '/00'.
        perform bdc_field using 'BSEG-WRBTR'
                                 WA_HEAD-WRBTR.
        perform bdc_field using 'BSEG-VALUT'
                                '03/27/2006'.
        perform bdc_field using 'BSEG-ZUONR'
                                 WA_HEAD-ZUONR.
        perform bdc_field using 'BSEG-SGTXT'
                                 WA_HEAD-SGTXT.
        perform bdc_field using 'RF05A-NEWBS'
                                 WA_HEAD-NEWBS.
        perform bdc_field using 'RF05A-NEWKO'
                                '574130'.
        perform bdc_field using 'DKACB-FMORE'
                                'X'.
        perform bdc_dynpro using 'SAPLKACB' '0002'.
        perform bdc_field using 'BDC_CURSOR'
                                'COBL-GSBER'.
        perform bdc_field using 'BDC_OKCODE'
                                '=ENTE'.
        perform bdc_field using 'COBL-GSBER'
                                '101'.
        perform bdc_dynpro using 'SAPMF05A' '0300'.
        perform bdc_field using 'BDC_CURSOR'
                                'BSEG-SGTXT'.
        perform bdc_field using 'BDC_OKCODE'
                                '=BP'.
        perform bdc_field using 'BSEG-WRBTR'
                                 WA_HEAD-WRBTR.
        perform bdc_field using 'BSEG-VALUT'
                                '03/27/2006'.
        perform bdc_field using 'BSEG-ZUONR'
                                 WA_HEAD-ZUONR.
        perform bdc_field using 'BSEG-SGTXT'
                                 WA_HEAD-SGTXT.
        perform bdc_dynpro using 'SAPLKACB' '0002'.
        perform bdc_field using 'BDC_CURSOR'
                                'COBL-KOSTL'.
        perform bdc_field using 'BDC_OKCODE'
                                 '=ENTE'.
        perform bdc_field using 'COBL-GSBER'
                                '101'.
        perform bdc_field using 'COBL-KOSTL'
                                 WA_HEAD-KOSTL.
      ENDLOOP.
    BAPI PROGRAM----
    *& Report  ZBAPI_TEST
    REPORT  ZBAPI_TEST.
    DATA: BEGIN OF i_data OCCURS 0,
            text(255),
          END OF i_data.
    DATA: i_fico TYPE BAPIACHE09.
    *DATA: I_FICO1 TYPE BAPIACCR08.
    DATA: I_FICO1 TYPE BAPIACGL09.
    DATA: I_FICO3 TYPE BAPIACCR09.
    DATA: I_FICO2 TYPE BAPIACTX09.
    DATA: P_KEY TYPE BBSEG.
    *DATA: it_TAB LIKE TABLE OF i_fico INITIAL SIZE 0  WITH HEADER LINE.
    HEADER DETAILS FROM BAPI STRUCUTE BAPIACHE09
    DATA: BEGIN OF it_TAB1 OCCURS 0,   " BAPIACHE09
          bldat(8),                    " DOC DATE
          blart(2),                    " DOC TYPE
          bukrs(4),                    " COMPANY CODE
          BUDAT(8),                    " POSTING DATE
          XBLNR(16),                   " HEADER REF
          BKTXT(50),                   " HEADER TXT
          END OF IT_TAB1.
    DATA: it_TAB LIKE TABLE OF BAPIACHE09 INITIAL SIZE 0 WITH HEADER LINE .
    ITEM DETAILS FROM STRUCTURE OF BAPI G/L ACCOUNT ITEM BAPIACGL09.
    DATA: BEGIN OF IT_ITAB3 OCCURS 0,  " BAPIACGL09.
          HKONT(10),                   " General Ledger Account
          SGTXT(50),                   " ITEM TXT
          BUKRS(4),                    " Company Code
          KOSTL(10),                   " COST CENTER
          PRCTR(10),                   " PROFIT CENTER
          END OF IT_ITAB3.
    DETIALS OF CURRENCY ITEMS FROM STRUCTURE OF BAPI BAPIACCR09
    DATA: BEGIN OF IT_iTAB4 OCCURS 0,   " BAPIACCR09
          WAERS(5),                     " CURRENCY
          BAPIWRBTR(23),                " Amount in document currency
          BAPIFWBAS(23),                " Tax Base Amount in Document Currency
          END OF IT_ITAB4.
    TAX ITEM DETAILS FROM BAPI STRUCUTE BAPIACTX09.
    DATA: BEGIN OF IT_ITAB5 OCCURS 0,   " BAPIACTX09.
          MWSKZ(2),                     " Sales Tax Code
          TXJCD(15),                    " Tax Jurisdiction
          ACPI_TXJCD_DEEP(15),          " Tax jurisdiction code - jurisdiction for lowest level tax
          END OF IT_ITAB5.
    THIS IS FROM STRUCTURE BBSEG.
    DATA: BEGIN OF IT_TAB6 OCCURS 0,
          NEWBS(2),                     " Posting Key for the Next Line Item
          NEWUM(1),                     " Special G/L Indicator for the Next Line Item
          DMBTR(16),                    " Amount in local currency (batch input field)
          AUFNR(12),                    " Order Number
          DZUONR(18),                   " Assignment number
          ZTERM(4),                     " Terms of payment key
          ZFBDT(8),                     " Baseline Date.
          END OF IT_TAB6.
    DATA: v_index TYPE i.
    DATA: return TYPE TABLE OF bapiret2 INITIAL SIZE 0 WITH HEADER LINE.
    START-OF-SELECTION.
      CALL FUNCTION 'UPLOAD'
    EXPORTING
      CODEPAGE                      = ' '
      FILENAME                      = ' '
      FILETYPE                      = ' '
      ITEM                          = ' '
      FILEMASK_MASK                 = ' '
      FILEMASK_TEXT                 = ' '
      FILETYPE_NO_CHANGE            = ' '
      FILEMASK_ALL                  = ' '
      FILETYPE_NO_SHOW              = ' '
      LINE_EXIT                     = ' '
      USER_FORM                     = ' '
      USER_PROG                     = ' '
      SILENT                        = 'S'
    IMPORTING
      FILESIZE                      =
      CANCEL                        =
      ACT_FILENAME                  =
      ACT_FILETYPE                  =
        TABLES
          data_tab                      = i_data
    EXCEPTIONS
      CONVERSION_ERROR              = 1
      INVALID_TABLE_WIDTH           = 2
      INVALID_TYPE                  = 3
      NO_BATCH                      = 4
      UNKNOWN_ERROR                 = 5
      GUI_REFUSE_FILETRANSFER       = 6
      OTHERS                        = 7
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    CALL FUNCTION 'BAPI_ACC_GL_POSTING_CHECK'
    EXPORTING
      DOCUMENTHEADER       =
       TABLES
         ACCOUNTGL            = it_tab1
      CURRENCYAMOUNT       =
         RETURN               = return.
      CALL FUNCTION 'BAPI_ACC_DOCUMENT_POST'
        EXPORTING
          DOCUMENTHEADER         =  it_tab
        TABLES
         ACCOUNTGL               = it_Itab3
         ACCOUNTRECEIVABLE       = it_Itab4
      ACCOUNTPAYABLE         =
         ACCOUNTTAX              = it_Itab5
       CURRENCYAMOUNT        =
      CRITERIA               =
      VALUEFIELD             =
      EXTENSION1             =
          RETURN                 =  return.
      loop at return.
        write:/ return-message,return-type.
      endloop.

    Try BAPI_ACC_GL_POSTING_POST.
    CALL FUNCTION 'BAPI_ACC_GL_POSTING_POST'
      EXPORTING
        DOCUMENTHEADER       =
        IMPORTING
              OBJ_TYPE             =
              OBJ_KEY              =
              OBJ_SYS              =
      TABLES 
             ACCOUNTGL            =   
            CURRENCYAMOUNT       =   
           RETURN               =
             EXTENSION1           =

  • Difference betrween BAPI and RFC

    Hi All
              Can anyone tell me the difference between BAPI and RFC.
    I am unable to find it out ,except one,ie  BAPI is based on object oriented concept .
    please justify your answers with real scenerios.

    Remote Function Call:
    RFC is an SAP interface protocol. Based on CPI-C, it considerably simplifies the programming of communication processes between systems.
    RFCs enable you to call and execute predefined functions in a remote system - or even in the same system.
    RFCs manage the communication process, parameter transfer and error handling.
    http://help.sap.com/saphelp_47x200/helpdata/en/22/042860488911d189490000e829fbbd/frameset.htm.
    BAPI
    BAPI stands for Business API(Application Program Interface).
    A BAPI is remotely enabled function module
    ie it can be invoked from remote programs like standalone JAVA programs, web interface etc..
    You can make your function module remotely enabled in attributes of Function module but
    A BAPI are standard SAP function modules provided by SAP for remote access.
    Also they are part of Businees Objest Repository(BOR).
    BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects.
    You create business objects and those are then registered in your BOR (Business Object Repository)
    which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA.
    In this case u only specify the business object and its method from external system
    in BAPI there is no direct system call. while RFC are direct system call.
    Some BAPIs provide basic functions and can be used for most SAP business object types.
    These BAPIs should be implemented the same for all business object types.
    Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs.
    Whenever possible, a standardized BAPI must be used in preference to an individual BAPI.
    Difference Between BAPI and RFC
    What is the main difference between BAPI and RFC and difference between BAPI and BDC?
    BAPI is used only when it is available for the particular transaction like Delivery Sales order. but BDC can be used for any
    transaction which have screen and fields.
    BAPI is directly updated the database instead BDC run through the screen flow.
    So BAPI can't handle all the flow logic checking and enhancement put by programmer to faciliate the user requirement.
    Difference between BAPI and BDC:
    BAPI is a higher end usage for tranfering the data from SAP to non-SAP and vice-versa. for ex: if we are using VB application,where in that we want to connect to SAP and retireve the data,and then change and update the data in SAP for that purpose we can use that.
    Apart from that, we can also use it for Uploading/Downloading the data from SAP to Non-SAP like BDC, provided we have an existing BAPI for that.
    BAPI function modules will also do all the checks required for data integrity like Transactions for BDC.
    There is one more advantage using BAPI instead of BDC. When we go for upgradation, there might be pozzibility to change the screen elements for transactions depending on the requirement. In that case,our BDC pgm may or may not work (depending on the screen changes they have made). Unless and until we prepare new BDC we cant use the old BDC pgm. But in BAPI, SAP promises that they are going to keep the old BAPI and for new functionality they will provide an upgraded BAPI. Until we write a new BAPI pgm, we can use the exisitng BAPI pgm.
    BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects. You create business objects and those are then registered in your BOR (Business Object Repository) which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA.
    In this case you only specify the business object and its method from external system in BAPI there is no direct system call. while RFC are direct system call Some BAPIs provide basic functions and can be used for most SAP business object types. These BAPIs should be implemented the same for all business object types. Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs. Whenever possible, a standardized BAPI must be used in preference to an individual BAPI. It is not possible to connect SAP to Non-SAP systems to retrieve data using RFC alone. RFC can acces the SAP from outside only through BAPI and same is for vice versa access.
    RFC is the protocol used by SAP for remote communication, that is, for communications between remote (independent) systems. RFC is used for communications between two independent SAP systems, or for communications between an SAP system and a non-SAP system, such as an external application. It can also be used for communications between modules on the same system. Using the RFC interfaces you can extend the functionality of R/3 applications from an external program.
    BAPI-step by step
    http://www.sapgenie.com/abap/bapi/example.htm
    list of all bapis
    http://www.planetsap.com/LIST_ALL_BAPIs.htm
    for BAPI's
    http://www.sappoint.com/abap/bapiintro.pdf
    http://www.sappoint.com/abap/bapiprg.pdf
    http://www.sappoint.com/abap/bapiactx.pdf
    http://www.sappoint.com/abap/bapilst.pdf
    http://www.sappoint.com/abap/bapiexer.pdf
    http://service.sap.com/ale
    http://service.sap.com/bapi
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE8/BCFESDE8.pdf
    http://www.planetsap.com/Bapi_main_page.htm
    http://www.topxml.com/sap/sap_idoc_xml.asp
    http://www.sapdevelopment.co.uk/
    http://www.sapdevelopment.co.uk/java/jco/bapi_jco.pdf
    also refer these threads
    What is the difference between RFC and BAPI?.
    whats difference between rfc and bapi?
    difference between rfc & bapi
    difference between RFC and BAPi
    Difference between BAPI and RFC?
    also chk this
    http://www.sap-img.com/abap/interview-question-on-bapi-rfc-abap-objects-tables.htm
    regards,
    srinivas
    <b>*reward for useful answers*</b>

  • BAPI vs BDCs

    What is the difference between BAPIs and BDCs...why BAPIs are preferred...? i know you might have gone through this question a zillion times....but the thing that bugs me the most is the fact that...if BAPIs are a better choise to transfer data as compared to BDCs...then where on earth are the field validations done  in BAPIs.? ...how is data integrity maintained if data is transferred through BAPIs? ( since data is not passed through screens...no validations are done)

    Hi,
    Difference between BDC and BAPI
    BDC is traditional way of coding the transactions for uploading the legacy data, Sap is changing all transactions to Object oriented programming. Since BAPI is Object based and supports all the new transactions it is preffered over BDC. More over BAPI's process data faster than BDC.
    BAPI is a SAP-supplied function module with a defined interface, which allows you to interact with various business objects. SAP guarantees the integrity of your database for anything updated using a BAPI. BDC is a method of driving screens programatically, for updating SAP data. BAPIs are generally faster than BDCs.
    A BAPI is faster because it is updating the DB "directly". Whereas BDC with call
    transaction goes through the whole screen sequence like any user would do, simply put, fills screens.
    However - there is not always a BAPI for a particular transaction and not all functions that are performed by a transaction can be done by a BAPI. BDCs produce error sessions which can be processed by the user, while BAPIs don't.
    First choose the BAPI ,if there is no BAPI go for BDC.
    why BAPI first not BDC.
    SAP comes up with Change in Version, so each and every time they will change the screens/number etc.
    so you have to change your BDC programs accordingly.
    and also Most of the Latest versions transactions are Enjoy Transaction. they will not support BDC's in Background.
    But Using BAPI's No such disadvantages.
    A BAPI is faster because it is updating the DB "directly" through ABAP code.
    A BDC with call transaction goes through the whole screen sequence like any user would do, simply put, it is filling screens.
    Actually it depends on your requirement but BAPI is more effective as it is standard function module to update SAP databases rather than BDC.
    using bdc over bapi has advantages and also disadvantages
    advantages:
    1. using bdc we can upload data into database tables using 2 ways
    1. foreground
    means that user interaction is there for each and every record.
    2. back ground -
    no user interaction and tasks are done automatically.
    using these two options is one of the greatest advantage over bapi.
    2. in bdc call transaction method we can control the display of screen resolution which is not possible with bapi's
    3. bdc is generally used for transferring of large amount of data than bapi's
    4.session method of bdc allows us to place data directly in application server and then finally transfered into sap database tables
    disadvantages:
    1.bdc is only used for sap to sap system data transferring
    2. bapis's generally works more faster than bdc's
    3. using bapis we can connect to remote systems and also to non sap systems.
    if useful reward some points.
    A BAPI is a method of a SAP Business Object. BAPI enables SAP and third party applications to interact and integrate
    with each other at the Business Object / Process level.
    Check this link to know more about BAPI.
    http://www.sapgenie.com/abap/bapi/example.htm
    http://sappoint.com/abap/
    Batch Data Communication (BDC) is the oldest batch interfacing technique that SAP provided since the early versions of R/3. BDC is not a
    typical integration tool, in the sense that, it can be only be used for uploading data into R/3 and so it is not bi-directional.
    BDC works on the principle of simulating user input for transactional screen, via an ABAP program. Typically the input comes in the form
    of a flat file. The ABAP program reads this file and formats the input data screen by screen into an internal table (BDCDATA). The
    transaction is then started using this internal table as the input and executed in the background.
    In ‘Call Transaction’, the transactions are triggered at the time of processing itself and so the ABAP program must do the error handling.
    It can also be used for real-time interfaces and custom error handling & logging features. .
    To know more about BDC,
    check the link.
    http://sappoint.com/abap/
    Main differences are...
    In case of bdc data transfer takes place from flat file into sap system ie the file existing in sap system to sap sytem
    where is bapi's r remotly enabled function modules which are assigned to some business objects n used to transfer the data between different business partners who are using different systems other than sap.
    not only that...
    when you plan to upgrade your system version then bdc willnot support those upgradations where as bapi's will support.
    Reward Points if found helpfull..
    Cheers,
    Chandra Sekhar.

  • Differences between bapi's and bdc

    Hi Frendz,
    What are the most imp differences between BAPI's and BDC ?
    Points for sure...
    Thanks in advance
    Vijaya

    Hi Vijaya,
    A few inputs from net
    BAPI is used only when it is available for the particular  transaction like Delivery Sales order. but BDC can be used for any 
    transaction which have screen and fields.
    BAPI is directly updated the database instead BDC run through the screen flow.
    So BAPI can't handle all the flow logic checking and enhancement put by programmer to faciliate the user requirement.
    BAPI is a higher end usage for tranfering the data from SAP to non-SAP and vice-versa. for ex: if we are using VB application,where in that we want to connect to SAP and retireve the data,and then change and update the data in SAP for that purpose we can use that.
    Apart from that, we can also use it for Uploading/Downloading the data from SAP to Non-SAP like BDC, provided we have an existing  BAPI for that. 
    BAPI function modules will also do all the checks required for data integrity like Transactions for BDC.
    There is one more advantage using BAPI instead of BDC.
    When we go for upgradation, there might be pozzibility to change the screen elements for transactions depending on the requirement. In that case,our BDC pgm may or may not work (depending on the screen changes they have made). Unless and until we prepare new BDC we cant use the old BDC pgm. But in BAPI, SAP promises that they are going to keep the old BAPI and for new functionality they will provide an upgraded BAPI. Until we write a new BAPI pgm, we can use the exisitng BAPI pgm.
    Source: sap-img.com
    this somehow summarzes what i wanted to convey and hence have put this extract.. hope it helps to your question.
    Br,
    Sri
    Award points for helpful answers

  • BAPI,BADI ,BDC,ALE ,IDOC,USER EXIT,VALIDATION AND SMART FORMS.

    Dear Experts,
    I am pretty new in BAPI,BADI ,BDC,ALE ,IDOC,USER EXIT,VALIDATION AND SMART FORMS.
    Pls let me know for these topics shall i put the question in this community or should i put in any other form. Pl suggest me .
    Regards
    Shivas

    Plz SEARCH in SCN before posting ,you will get lot of posts .
    Don't use all caps in the subject line

  • Re:Bapi's and Bdc's

    hi friends,
                     Iam new to Bapi's and Bdc's plz tell me which sites are good for learning and i also want some realtime examples or codes.
    Thanks in advance.

    Hi
    what is BAPI?
    BAPI stands for Business API(Application Program Interface).
    A BAPI is remotely enabled function module ie it can be invoked from remote programs like standalone JAVA programs, web interface etc..
    You can make your function module remotely enabled in attributes of Function module but
    A BAPI are standard SAP function modules provided by SAP for remote access. Also they are part of Businees Objest Repository(BOR).
    BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects. You create business objects and those are then registered in your BOR (Business Object Repository) which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA. in this case u only specify the business object and its method from external system in BAPI there is no direct system call. while RFC are direct system call Some BAPIs provide basic functions and can be used for most SAP business object types. These BAPIs should be implemented the same for all business object types. Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs. Whenever possible, a standardized BAPI must be used in preference to an individual BAPI.
    The following standardized BAPIs are provided:
    Reading instances of SAP business objects
    GetList ( ) With the BAPI GetList you can select a range of object key values, for example, company codes and material numbers.
    The BAPI GetList() is a class method.
    GetDetail() With the BAPI GetDetail() the details of an instance of a business object type are retrieved and returned to the calling program. The instance is identified via its key. The BAPI GetDetail() is an instance method. BAPIs that can create, change or delete instances of a business object type
    The following BAPIs of the same object type have to be programmed so that they can be called several times within one transaction. For example, if, after sales order 1 has been created, a second sales order 2 is created in the same transaction, the second BAPI call must not affect the consistency of the sales order 2. After completing the transaction with a COMMIT WORK, both the orders are saved consistently in the database.
    Create( ) and CreateFromData! ( )
    The BAPIs Create() and CreateFromData() create an instance of an SAP business object type, for example, a purchase order. These BAPIs are class methods.
    Change( )
    The BAPI Change() changes an existing instance of an SAP business object type, for example, a purchase order. The BAPI Change () is an instance method.
    Delete( ) and Undelete( ) The BAPI Delete() deletes an instance of an SAP business object type from the database or sets a deletion flag.
    The BAPI Undelete() removes a deletion flag. These BAPIs are instance methods.
    Cancel ( ) Unlike the BAPI Delete(), the BAPI Cancel() cancels an instance of a business object type. The instance to be cancelled remains in the database and an additional instance is created and this is the one that is actually canceled. The Cancel() BAPI is an instance method.
    Add<subobject> ( ) and Remove<subobject> ( ) The BAPI Add<subobject> adds a subobject to an existing object inst! ance and the BAPI and Remove<subobject> removes a subobject from an object instance. These BAPIs are instance methods.
    BAPI-step by step
    http://www.sapgenie.com/abap/bapi/example.htm
    list of all bapis
    http://www.planetsap.com/LIST_ALL_BAPIs.htm
    for BAPI's
    http://www.sappoint.com/abap/bapiintro.pdf
    http://www.sappoint.com/abap/bapiprg.pdf
    http://www.sappoint.com/abap/bapiactx.pdf
    http://www.sappoint.com/abap/bapilst.pdf
    http://www.sappoint.com/abap/bapiexer.pdf
    http://service.sap.com/ale
    http://service.sap.com/bapi
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE8/BCFESDE8.pdf
    http://www.planetsap.com/Bapi_main_page.htm
    http://www.topxml.com/sap/sap_idoc_xml.asp
    http://www.sapdevelopment.co.uk/
    http://www.sapdevelopment.co.uk/java/jco/bapi_jco.pdf
    Also refer to the following links..
    www.sappoint.com/abap/bapiintro.pdf
    www.sap-img.com/bapi.htm
    www.sap-img.com/abap/bapi-conventions.htm
    www.planetsap.com/Bapi_main_page.htm
    www.sapgenie.com/abap/bapi/index.htm
    Checkout !!
    http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
    http://techrepublic.com.com/5100-6329-1051160.html#
    http://www.sap-img.com/bapi.htm
    http://www.sap-img.com/abap/bapi-conventions.htm
    http://www.sappoint.com/abap/bapiintro.pdf
    u can check the below the material also
    Example Code
    U need to give the step_nr, item_nr, cond_count and cond_type so the correct conditon will be updated. If no condition exists for the given parameters, a new condition will be created.
    U can find these parameters for a particular condition type in table KONV.
    *& Form saveTransactionJOCR
    text
    --> p1 text
    <-- p2 text
    FORM saveTransactionJOCR .
    data: salesdocument like BAPIVBELN-VBELN,
    order_header_inx like bapisdh1x,
    order_header_in like bapisdh1,
    return type standard table of bapiret2 with header line,
    conditions_in type standard table of bapicond with header line,
    conditions_inx type standard table of bapicondx with header line,
    logic_switch like BAPISDLS,
    step_nr like conditions_in-cond_st_no,
    item_nr like conditions_in-itm_number,
    cond_count like conditions_in-cond_count,
    cond_type like conditions_in-cond_type.
    salesdocument = wa_order_information-VBELN.
    LOGIC_SWITCH-COND_HANDL = 'X'.
    order_header_inx-updateflag = 'U'.
    conditions
    clear conditions_in[].
    clear conditions_inx[].
    clear: step_nr,
    item_nr,
    cond_count,
    cond_type.
    step_nr = '710'.
    item_nr = '000000'.
    cond_count = '01'.
    cond_type = 'ZCP2'.
    CONDITIONS_IN-ITM_NUMBER = item_nr.
    conditions_in-cond_st_no = step_nr.
    CONDITIONS_IN-COND_COUNT = cond_count.
    CONDITIONS_IN-COND_TYPE = cond_type.
    CONDITIONS_IN-COND_VALUE = 666.
    CONDITIONS_IN-CURRENCY = 'EUR'.
    append conditions_in.
    CONDITIONS_INX-ITM_NUMBER = item_nr.
    conditions_inx-cond_st_no = step_nr.
    CONDITIONS_INX-COND_COUNT = cond_count.
    CONDITIONS_INX-COND_TYPE = cond_type.
    CONDITIONS_INX-UPDATEFLAG = 'U'.
    CONDITIONS_INX-COND_VALUE = 'X'.
    CONDITIONS_INX-CURRENCY = 'X'.
    append conditions_inx.
    CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
    EXPORTING
    SALESDOCUMENT = salesdocument
    ORDER_HEADER_IN = order_header_in
    ORDER_HEADER_INX = order_header_inx
    LOGIC_SWITCH = logic_switch
    TABLES
    RETURN = return
    CONDITIONS_IN = conditions_in
    CONDITIONS_INX = conditions_inx
    if return-type ne 'E'.
    commit work and wait.
    endif.
    ENDFORM. " saveTransactionJOCR
    Bdc to Bapi
    The steps to be followed are :
    1. Find out the relevant BAPI (BAPI_SALESORDER_CHANGE for VA02).
    [for VA01 use BAPI_SALESORDER_CREATEFROMDAT2]
    2. Create a Z program and call the BAPi (same as a Funtion module call).
    2. Now, if you see this BAPi, it has
    -> Importing structures.
    eg: SALESDOCUMENT: this will take the Sales order header data as input.
    -> Tables parameters:
    eg: ORDER_ITEM_IN: this will take the line item data as input.
    Note :
    Only specify fields that should be changed
    Select these fields by entering an X in the checkboxes
    Enter a U in the UPDATEFLAG field
    Always specify key fields when changing the data, including in the checkboxes
    The configuration is an exception here. If this needs to be changed, you need to complete it again fully.
    Maintain quantities and dates in the schedule line data
    Possible UPDATEFLAGS:
    U = change
    D = delete
    I = add
    Example
    1. Delete the whole order
    2. Delete order items
    3. Change the order
    4. Change the configuration
    Notes
    1. Minimum entry:
    You must enter the order number in the SALESDOCUMENT structure.
    You must always enter key fields for changes.
    You must always specify the update indicator in the ORDER_HEADER_INX.
    2. Commit control:
    The BAPI does not run a database Commit, which means that the application must trigger the Commit so that the changes are read to the database. To do this, use the BAPI_TRANSACTION_COMMIT BAPI.
    For further details... refer to the Function Module documentation for the BAPi.
    Bapi to VB(Visual Basic)
    Long back I had used the following flow structure to acheive the same.
    Report -> SM59 RFC destination -> COM4ABAP -> VB.exe
    my report uses the rfc destination to create a COM session with com4abap. com4abap calls the vb.exe and manages the flow of data between sap and vb exe.
    You need to have com4abap.exe
    If com4abap is installed you will find it in sapgui installatin directory , C:Program FilesSAPpcsapguiRFCSDKcom4abap.
    else refer OSS note 419822 for installation of com4abap
    after making the settings in com4abap to point to the vb program and setting up rfc destination in sm59 to point to com4abap session , you can use the following function modules to call the vb code.
    for setting up com4abap and rfc destination please refer to the documentation for com4abap.
    Invoke NEW DCOM session
    call function 'BEGIN_COM_SESSION'
    exporting
    service_dest = service_dest "(this will be a RFC destination created in SM59)
    importing
    worker_dest = worker_dest
    exceptions
    connect_to_dcom_service_failed = 1
    connect_to_dcom_worker_failed = 2
    others = 3.
    call function 'create_com_instance' destination worker_dest
    exporting
    clsid = g_c_clsid
    typelib = g_c_typelib
    importing
    instid = g_f_oid
    exceptions
    communication_failure = 1 message g_f_msg
    system_failure = 2 message g_f_msg
    invalid_instance_id = 3
    others = 4.
    call function 'com_invoke' destination worker_dest
    exporting
    %instid = g_f_oid
    %method = 'UpdatePDF'
    sntemp = g_v_const_filent
    snsysid = sy-sysid
    snflag = 'N'
    tables
    rssaptable = g_t_pdfdetail1
    %return = g_t_pdfdetail1 "t_test
    exceptions
    communication_failure = 1 message g_f_msg
    system_failure = 2 message g_f_msg
    invalid_instance_id = 3
    others = 4.
    then close the com session , using
    FM delete_com_instance
    FM END_COM_SESSION
    BDC
    BDC:
    Batch Data Communication (BDC) is the process of transferring data from one SAP System to another SAP system or from a non-SAP system to SAP System.
    Features :
    BDC is an automatic procedure.
    This method is used to transfer large amount of data that is available in electronic medium.
    BDC can be used primarily when installing the SAP system and when transferring data from a legacy system (external system).
    BDC uses normal transaction codes to transfer data.
    Types of BDC :
    CLASSICAL BATCH INPUT (Session Method)
    CALL TRANSACTION
    BATCH INPUT METHOD:
    This method is also called as ‘CLASSICAL METHOD’.
    Features:
    Asynchronous processing.
    Synchronous Processing in database update.
    Transfer data for more than one transaction.
    Batch input processing log will be generated.
    During processing, no transaction is started until the previous transaction has been written to the database.
    CALL TRANSACTION METHOD :
    This is another method to transfer data from the legacy system.
    Features:
    Synchronous processing. The system performs a database commit immediately before and after the CALL TRANSACTION USING statement.
    Updating the database can be either synchronous or asynchronous. The program specifies the update type.
    Transfer data for a single transaction.
    Transfers data for a sequence of dialog screens.
    No batch input processing log is generated.
    For BDC:
    http://myweb.dal.ca/hchinni/sap/bdc_home.htm
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/home/bdc&
    http://www.sap-img.com/abap/learning-bdc-programming.htm
    http://www.sapdevelopment.co.uk/bdc/bdchome.htm
    http://www.sap-img.com/abap/difference-between-batch-input-and-call-transaction-in-bdc.htm
    http://help.sap.com/saphelp_47x200/helpdata/en/69/c250684ba111d189750000e8322d00/frameset.htm
    http://www.sapbrain.com/TUTORIALS/TECHNICAL/BDC_tutorial.html
    Check these link:
    http://www.sap-img.com/abap/difference-between-batch-input-and-call-transaction-in-bdc.htm
    http://www.sap-img.com/abap/question-about-bdc-program.htm
    http://www.itcserver.com/blog/2006/06/30/batch-input-vs-call-transaction/
    http://www.planetsap.com/bdc_main_page.htm
    call Transaction or session method ?
    Reward points if useful
    Regards
    Anji

  • Diff b/w BAPI and Function Module.

    What is the difference between BAPI and Function Module....
    By Interface programming do we mean posting data thru  BAPI,BDC....

    Hi Alex,
    BAPI: Standard Interface in the R/3 system that allows the system to communicate with components of other business suites.
    FM: These are the procedures that are defined in the Function Groups and can be called from any ABAP Program. FM allow you to encapsulate and reuse global functions int he R/3 system.
    The main basic difference between BAPI and FM are
    1) All BAPIs are FM but not all FMs are BAPIs
    2) BAPIs are remote enabled
    3) BAPIs interface will not have a changing and exceptions. They can not be used to have use dialog.
    Interface programs can post data to SAP either through a BDC, BAPI, IDOC etc. It depends on the type of requirement.
    Hope this solves your question.
    Enjoy SAP
    Rajasekhar

  • Differnce b'w lsmw and bdc

    pls tell the differnce b'w lsmw and bdc . when we use bdc and when we use lsmw .for uploading master data (ex: cusomer data ) in tosap which method s u prrefer out of thhse  4
    method scall transaction
    session input
    lsmw bapi  whic one is the better one
    when use session  method and when we use call tran sac
    which method is better for bacjground processing call tran s or session method . pls tell
    the reason
    answres as soon as possible

    Hi,
    LSMW IS JUST A TOOL TO GET THE DATA FROM A LEGACY SYSTEM.
    IN BDC WE HAVE 2 WRITE THE CODE AND CALL THE REQUIRED METHOD
    THATS IT. IN FUNCTIONALITY PERSPECTIVE THERE IS NO
    DIFFERENCE.
    BDC is Batch Data Communication. It is basically a program
    either generated by SAP after a recording or programmed by a
    abaper.Its like running the transaction manually but all the
    data is populated on the screens automatically.It is a
    little complex when the screens contain table controls.
    LSMW is legacy system migration workbench is a more user-
    friendly tool thru which one can do the same as a BDC. One
    just has to follow some 14 steps, click buttons and the data
    is set to be uploaded &#8230;.LSMW offer you 4 ways to import data
    into SAP, they are BDC, Direct Input, BAPI(BO), IDOC.
    To spell out the differences in detail:
    look at the below threads to know more
    Diff between LSmw and Bdc
    Diff. between LSMW & BDC
    Regards
    Sudheer

  • Mass maintenance and BDC Recodring of custom fields added in PO header.

    Hello Experts,
    I have created a custom fields in PO header and used  Structure for BADI implementation to update the header with values enterd in custom table.
    My requirement is for some selected PO i want to fix the value of one of my custom field at header level.
    I have tried both the options Mass maintenance and BDC recording but the issue i'm facing is when i go for mass maintenance it is giving me the ERROR and it seems that we can only do the mass maintenance for sap-standard fields only.
    When i go for BDC recording i'm facing the issue that when i do SHDB and start recording  for ME22N my custom field is coming  grayed out and i'm not able to input the desired value in custom field and complete my recording.
    Let me know your valuable inputs .
    Thanks,
    Naveen

    Hello,
    Instead of BDC i'm doing it through the BAPI   "BAPI_PO_CHANGE" by populating the structure extensionin but here i'm facing the error as below:-
    W     ME     887     Error transferring ExtensionIn data for enhancement CI_EKKODB
    E     BAPI     003     Instance 4500001544 of object type PurchaseOrder could not be changed
    below is my code:-
    ls_extensionin-structure = 'BAPI_TE_MEPOHEADER'.
        ls_extensionin-valuepart1+0(10) = wa_po-ebeln.
        ls_extensionin-valuepart1+14(3) = no.
        append ls_extensionin to lt_extensionin.
        clear:ls_bapi_te_bg,ls_extensionin.
        ls_extensionin-structure = 'BAPI_TE_MEPOHEADERX'.
        ls_extensionin-valuepart1+0(10) = wa_po-ebeln.
        ls_extensionin-valuepart1+10(1) = 'X'.
        append ls_extensionin to lt_extensionin.
        clear:ls_bapi_te_bg,ls_extensionin.
        call function 'BAPI_PO_CHANGE'
            exporting
              purchaseorder                = wa_po-ebeln
            tables
              return                       = it_bapireturn
              extensionin                  = lt_extensionin
        if it_bapireturn[] is initial.
          call function 'BAPI_TRANSACTION_COMMIT'
            exporting
              wait   = ' '
            importing
              return = it_bapireturn.
        endif.
        refresh lt_extensionin[].
      endloop.
    Please let me know if there is any way to achieve this.
    Thanks,
    naveen

  • Difference Between BAPI And RFC in ABAP

    Hi,
    i want to know difference between BAPI and RFC in SAP,
    can we call SAP GUI screen from NON SAP System Using BAPI.
    Reg,
    Hariharan

    Hi Ravishankar,
    The difference is not importat while you understand the concept.
    I think, RFC is the protocol for calling functions from external systems in R/3.
    I understand like BAPI a series of complet functions that SAP offers you for use and model a business use.
    But if I need program a function that can be called for external system i would call it RFC_NAME, because is a unique function that makes a single task.
    In other words, the difference i think is about work idea more than another thing.
    RFC
    A remote function call is a call to a function module running in a system different from the caller's. The remote function can also be called from within the same system (as a remote call).
    RFC consists of two interfaces : A calling interface for ABAP Programs and a calling interface for Non-SAP programs.
    The RFC Interface takes care of :-
    - Converting all parameter data to the representation needed in the remote system
    Calling the communication routines needed to talk to the remote system.
    Handling communications errors, and notifying the caller, if desired ( using EXCEPTIONS paramater of the CALL FUNCTION).
    BAPI
    BAPIs are standardized programming interfaces (methods) enabling external applications to access business processes and data in the R/3 System.
    BAPIs provide stable and standardized methods to achieve seamless integration between the R/3 System and external applications, legacy systems and add-ons.
    BAPIs are defined in the BOR(Business object repository) as methods of SAP business object types that carry out specific business functions.
    BAPIs are implemented as RFC-enabled function modules and are created in the Function Builder of the ABAP Workbench.
    The most critical difference btwn BAPI and FM is that BAPI can be wrapped in Business objects whereas RFC cant.
    BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects. You create business objects and those are then registered in your BOR (Business Object Repository) which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA. in this case u only specify the business object and its method from external system in BAPI there is no direct system call. while RFC are direct system call Some BAPIs provide basic functions and can be used for most SAP business object types. These BAPIs should be implemented the same for all business object types. Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs. Whenever possible, a standardized BAPI must be used in preference to an individual BAPI.
    The following standardized BAPIs are provided:
    Reading instances of SAP business objects
    GetList ( ) With the BAPI GetList you can select a range of object key values, for example, company codes and material numbers.
    The BAPI GetList() is a class method.
    GetDetail() With the BAPI GetDetail() the details of an instance of a business object type are retrieved and returned to the calling program. The instance is identified via its key. The BAPI GetDetail() is an instance method. BAPIs that can create, change or delete instances of a business object type
    The following BAPIs of the same object type have to be programmed so that they can be called several times within one transaction. For example, if, after sales order 1 has been created, a second sales order 2 is created in the same transaction, the second BAPI call must not affect the consistency of the sales order 2. After completing the transaction with a COMMIT WORK, both the orders are saved consistently in the database.
    Create( ) and CreateFromData! ( )
    The BAPIs Create() and CreateFromData() create an instance of an SAP business object type, for example, a purchase order. These BAPIs are class methods.
    Change( )
    The BAPI Change() changes an existing instance of an SAP business object type, for example, a purchase order. The BAPI Change () is an instance method.
    Delete( ) and Undelete( ) The BAPI Delete() deletes an instance of an SAP business object type from the database or sets a deletion flag.
    The BAPI Undelete() removes a deletion flag. These BAPIs are instance methods.
    Cancel ( ) Unlike the BAPI Delete(), the BAPI Cancel() cancels an instance of a business object type. The instance to be cancelled remains in the database and an additional instance is created and this is the one that is actually canceled. The Cancel() BAPI is an instance method.
    Add<subobject> ( ) and Remove<subobject> ( ) The BAPI Add<subobject> adds a subobject to an existing object inst! ance and the BAPI and Remove<subobject> removes a subobject from an object instance. These BAPIs are instance methods.
    Check these Links out
    http://searchsap.techtarget.com/ateQuestionNResponse/0,289625,sid21_cid558752_tax293481,00.html
    http://www.sap-img.com/abap/interview-question-on-bapi-rfc-abap-objects-tables.htm
    http://www.sap-img.com/fu033.htm
    http://www.sap-img.com/abap/ale-bapi.htm
    Refer following SDN threads:
    Diff. Between BAPI and RFC
    Re: BAPI and RFC
    Hope this resolves your query.
    Reward all the helpful answers.
    Regards

Maybe you are looking for

  • Adobe Creative Suite 5.5 Production Premium: Number of DVD discs and content

    I am currently trying to source Adobe CS 5.5 Production Premium second hand. Is anybody able to tell me the number of discs (DVD's) this package is on. I thought it was four, but may be incorrect. I am concerned of buying from someone not having all

  • Service error '"Service 'Apple Mobile Device' (Apple Mobile Device) failed to start..."  keeps me from reinstalling iTunes

    I get the following error: I have admin priviliges on the PC.  I am running Windows 7, 64 Bit OS.  Any suggestions to resolve this issue. 

  • ITunes updater not working

    I already have iTunes, and I've been using iTunes for about a year. When I opened iTunes today, it told me a newer version was avalible, so I clicked yes to install the new iTunes. It came up fine and went through all the normal operations, until it

  • Old iPod issue

    I have an old 15GB version 2.3 and its formated for a macintosh, I purchased a tunetransfer program that I thought was for macs, but i brought it home and found out that its for windows. So I ran parallel on my new laptop so I could use the program o

  • Hide (not disable, hide) a button

    Hello people! Somebody can tell my how i can hide a button and how i can changed the label, i tryed with set itemproperty('button', displayed, PROPERTY_FALSE) & set_item_property('button', label, 'newname')for each case, but doesn´t work...any idea?