Using BAPI as WebService Interface in SAP PI

Hello,
Situation is:
BAPI is imported in SAP PI from SAP R/3 system.
The BAPI will be used for R/3 as Sync.Receiver.
A Web Application should connect to SAP PI with the same message structure for request and response.
So the idea is to publish the BAPI interface as a WSDL for this partner.
But when doing this in Directory SAP PI does not offer BAPIs as Interfaces for WSDL, only message interfaces created
in Repository are offered.
BAPIs are interfaces per definition. So we dont need a message interface to add the BAPI to it.
Maybe this woin t work anyhow with a SAP system.
But how to use the BAPI for a WSDL?
Is it required to create an interface for this purpose and add this one in the Directory WSDL create function?
Best regards
Dirk

Hi Meinhard,
There are more ways to get where you want to go, some are mentioned above.
You can also do the following:
1) From the BAPI you create the Webservice in R3 (as described in the link from pavan kumar)
2) Go to trx SOAMANGER (in R3)  and get the URL for the WSDL
3) Import the WSDL in PI as an External Definition (ED)
4) Now you create an INBOUND, synchronous, service interface with the external definition.
5) After saving the SI you can create a matching Outbound service interface (it's a menu option)
Now you can use these service interfaces in the Integration directory.
You can even create an ICO (integrated configuration) provided you use SOAP communication channels.
kr
Robert

Similar Messages

  • Where to find the XSLT used for the standard interface in SAP ME 5.2 SP05?

    Hallo!
    Starting with SAP ME 5.2 SP05 there is a new logic for the standard interface used in SAPMEINT.
    I wonder where to find the XSLT's that are used for transforming the XML messages?
    I can see from the SAP NW log:
    [Transaction: -1] starting execution of Visiprise/ERPShopFloorIntegration/frame/workflow/XSLTDelegate.trx
    Loading file Visiprise/WEB/XSLT/Outbound/EquipmentStatusChangeUnSchDown/EquipmentStatusChangeUnSchDownRequest.xslt
    select: path Visiprise/WEB/XSLT/Outbound/EquipmentStatusChangeUnSchDown
    select: name EquipmentStatusChangeUnSchDownRequest.xslt
    The definition for this XSLT is as follows:
    WEB://Visiprise/XSLT/Outbound/EquipmentStatusChangeUnSchDown/EquipmentStatusChangeUnSchDownRequest.xslt
    How is this resolved???
    From the (pre SP05) SAPMEINT I know two variants:
    1. High performance interface
    The XSLT files come from the MII shared memory entries for project SAPMEINT
    2. Standard interface
    The XSLT files come from SAP ME (table XSLT and XLST_ASSIGBNMENT) via calling a HTTP URL like
    http://<hostname>:<port>/manufacturing/vm/xslt?id=RouterFeed
    Kr,
           Erich Lind

    Hello!
    I found the answer myself now.
    The XLST files are part of the static web content of the MI project Visiprise.
    In the SAP MII workbench go to the project Visiprise
    Then under the tab Web the static contecnt can be found under the folder WEB/XSLT/..

  • SAP ECC 6.0 - Using BAPIs for C# to extract data out

    I have had a client recommend a strategy of extracting data usin C# (Visual Studio 2005) to extract data from SAP ECC using BAPIs.
    We do have an existing methodology in place using flat files to extract data to non SAP systems
    We have purchase XI which we intend to implement next year.
    I basically wanted to keep things tidy and continue with the flat file interface strategy just to keep things simple going forward to XI.
    THen there is also the security piece, the developer has had to slowly build a profile / roles that alows him to come in thru visual studio to access these BAPIs
    I am looking for anyone who has had experience with this and what your experiences are.  As well, what are the SAP best practicies concerning this strategy
    Thank YOU ALL who will reply

    I think that SAP's strategy toward exposing BAPI is leaning toward leveraging their AS-JAVA stack.  With the AS-JAVA Enterprise Services and standard delivered web content, SAP is already exposing many existing BAPI/Business Functionality outside of the ABAP world.   However, that's not saying that traditional flat files have no place in the future.  Matter of fact, I don't see flat/delimited files going away any time soon.
    It all really comes down to what you are doing, you may even end up with a landscape that's a mix of files/RFCs.  Here inhouse, we leverage file based transfers for large data sets such as SAP BI OHS extracts, and daily R/3 FI extracts.  Why file?  because it's simple, easy to control, and you can see the data being transferred.  A file can be "hold in my hands" if you will, at best there's just a few characters in-flight.
    As for RFCs, any type of RFCs in fact (Anything from sap .net connector to AS-JAVA ESOA Based ES), are basically designed for transactional data.  Here, you are looking at things that are high in transactional count but small in individual size.  Your client's call using C#, it all really depends on how you are doing it.  MOST IMPORTANTLY:  Make sure you are using a proven, standarized, and SAP supported way, PERIOD.  NEVER EVER go into production with a "hack".
    For the high-transactional-count-small-individual transactions, we leverage BizTalk Server (BTS) here.  I'll be frank, we are not using BTS because we wrote it.  We are using BTS because it just works better for us, in our environment.  BTS now support SAP 2.0 connector (registered program ID) and SAP 3.0 (WCF based, direct SAP RFC call, supported by Microsoft AND SAP).  We are leveraging these adapters and BTS (as distribution and transformation) in our environment more and more.
    So, long story short:  Determine the transaction type, multiple solutions is ok, make sure the solution is supported!

  • Using bapi how to upload the data into sap database?

    hi dear all,
                  im facing problem with bapi ? let me edcuate on bapi ..
    i will be  waiting for reply.
    my e-id :[email protected]
    thanks&regards
    shiva.

    Hi
    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.
    http://www.sap-img.com/abap/ale-bapi.htm
    SAP BAPI
    BAPI STEPS
    Hope this helps.
    ashish

  • Webservice Integration with SAP using SAP XI

    On a periodic basis, say end-of-shift, My product(Web service) sends to the SAP system the total production for that period, for example, Hot Metal produced. The data packet contains all theinformation required to uniquely identify the production period (plant name, location, furnace number, shift
    number, date & time).
    SAP receives the data packet, stores the data in appropriate tables and acknowledges the status to My Product. The acknowledgement contains total revenue generated based on the production (computed based on the unit cost of Hot Metal). If the data is incorrect, SAP sends a fault message. The revenue value received as response is stored in an appropriate tag in the My Product model.
    I want to use SAP XI as the connector between my webservice application and SAP. Please suggest me what scenario should I implement in this case. Do I need to use BPM here ?
    Also please suggest what are relevant IDocs and BAPIs for this scenario.

    Got it...

  • Send mail to non-sap using bapi's

    hi friends,
    Can any one please help me how to send mail from sap to non-sap systems using bapi's.plesae help me .i want the procedure and code
    regards
    srikanth.v

    Hi,
       Use this sample Code...
    REPORT ZSENDMAIL.
    DATA: OBJPACK LIKE SOPCKLSTI1 OCCURS 2 WITH HEADER LINE.
    DATA: OBJHEAD LIKE SOLISTI1 OCCURS 1 WITH HEADER LINE.
    DATA: OBJBIN LIKE SOLISTI1 OCCURS 10 WITH HEADER LINE.
    DATA: OBJTXT LIKE SOLISTI1 OCCURS 10 WITH HEADER LINE.
    DATA: RECLIST LIKE SOMLRECI1 OCCURS 5 WITH HEADER LINE.
    DATA: DOC_CHNG LIKE SODOCCHGI1.
    DATA: TAB_LINES LIKE SY-TABIX.
    Creation of the document to be sent
    File Name
    DOC_CHNG-OBJ_NAME = 'SENDFILE'.
    Mail Subject
    DOC_CHNG-OBJ_DESCR = 'Send External Mail'.
    Mail Contents
    OBJTXT = 'Minimum bid : $250000'.
    APPEND OBJTXT.
    OBJTXT = 'A representation of the pictures up for auction'.
    APPEND OBJTXT.
    OBJTXT = 'was included as attachment.'.
    APPEND OBJTXT.
    DESCRIBE TABLE OBJTXT LINES TAB_LINES.
    READ TABLE OBJTXT INDEX TAB_LINES.
    DOC_CHNG-DOC_SIZE = ( TAB_LINES - 1 ) * 255 + STRLEN( OBJTXT ).
    Creation of the entry for the compressed document
    CLEAR OBJPACK-TRANSF_BIN.
    OBJPACK-HEAD_START = 1.
    OBJPACK-HEAD_NUM = 0.
    OBJPACK-BODY_START = 1.
    OBJPACK-BODY_NUM = TAB_LINES.
    OBJPACK-DOC_TYPE = 'RAW'.
    APPEND OBJPACK.
    Creation of the document attachment
    (Assume that the data in OBJBIN is in BMP format)
    *OBJBIN = ' \O/ '. APPEND OBJBIN.
    *OBJBIN = ' | '. APPEND OBJBIN.
    *OBJBIN = ' / \ '. APPEND OBJBIN.
    *DESCRIBE TABLE OBJBIN LINES TAB_LINES.
    *OBJHEAD = 'PICTURE.BMP'.
    *APPEND OBJHEAD.
    Creation of the entry for the compressed attachment
    *OBJPACK-TRANSF_BIN = 'X'.
    *OBJPACK-HEAD_START = 1.
    *OBJPACK-HEAD_NUM = 1.
    *OBJPACK-BODY_START = 1.
    *OBJPACK-BODY_NUM = TAB_LINES.
    *OBJPACK-DOC_TYPE = 'BMP'.
    *OBJPACK-OBJ_NAME = 'PICTURE'.
    *OBJPACK-OBJ_DESCR = 'Representation of object 138'.
    *OBJPACK-DOC_SIZE = TAB_LINES * 255.
    *APPEND OBJPACK.
    Completing the recipient list
    RECLIST-RECEIVER = '[email protected]'.
    RECLIST-REC_TYPE = 'U'.
    APPEND RECLIST.
    *RECLIST-RECEIVER = 'SAPUSERNAME'.
    *RECLIST-REC_TYPE = 'P'.
    *APPEND RECLIST.
    Sending the document
    CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
    EXPORTING
    DOCUMENT_DATA = DOC_CHNG
    PUT_IN_OUTBOX = 'X'
    TABLES
    PACKING_LIST = OBJPACK
    OBJECT_HEADER = OBJHEAD
    CONTENTS_BIN = OBJBIN
    CONTENTS_TXT = OBJTXT
    RECEIVERS = RECLIST
    EXCEPTIONS
    TOO_MANY_RECEIVERS = 1
    DOCUMENT_NOT_SENT = 2
    OPERATION_NO_AUTHORIZATION = 4
    OTHERS = 99.
    CASE SY-SUBRC.
    WHEN 0.
    WRITE: / 'Result of the send process:'.
    LOOP AT RECLIST.
    WRITE: / RECLIST-RECEIVER(48), ':'.
    IF RECLIST-RETRN_CODE = 0.
    WRITE 'The document was sent'.
    ELSE.
    WRITE 'The document could not be sent'.
    ENDIF.
    ENDLOOP.
    WHEN 1.
    WRITE: / 'No authorization for sending to the specified number',
    'of recipients'.
    WHEN 2.
    WRITE: / 'Document could not be sent to any recipient'.
    WHEN 4.
    WRITE: / 'No send authorization'.
    WHEN OTHERS.
    WRITE: / 'Error occurred while sending'.
    ENDCASE.
    in this code....Internal table IF RECLIST-RETRN_CODE is not 0,then the mail is not send to the recipient, so if you want the undeliverable mail for a perticular recipient then call the same function module SO_NEW_DOCUMENT_ATT_SEND_API1 with undeliverd message to whom want to receive the undeliverd message.
    hope this solves your problem

  • Using the Open Catalog Interface (OCI) between SAP-ECC 6.0 and SAP-MDM

    Hello ASUG Community.
    I'm working on an SAP-MDM project where we will configure the OCI interface between SAP-ECC 6.0 and SAP-MDM.  The business requirement will be to punch out to SAP-MDM's catalog from SAP-ECC for expensed items (e.g., no material master record exists in SAP-ECC).
    The data that will be returned to SAP-ECC will be purchase price info, material group, short text, & our global SAP-MDM item number.
    The question I've been trying to design around is "where to store the SAP-MDM item number"?
    I've looked into creating a custom filed on EKPO but now feel that a configured text field will be the best solution from an SAP-ECC point of view (less effort on the SAP-ECC side from a development perspective, no need to regenerate the EKPO table, etc.).
    The question I'd like to pose to ASUG is.... Does anyone have experience or an opinion to offer using this functionality?  It seems that I will have to code in a user exit or BAdi to insure that the SAP-MDM item numbers are returned to the appropriate text field on my POu2019s.  Or can this be done using the standard OCI functionality?
    I found OSS note 1347656 which references BADI "ME_CATALOG_INTERFACE" but I'm not sure if this right path to go down or if this would be the correct place to code non-conforming OCI mapping requiremetns.
    Any insight would be most appreciated.
    Thanks.  Sincerely,
    Rich Wortmann

    I would suggest you create a new field for this as you may require thois going forward for reporting as well. Text fields are difficult to report.
    Sorry not sure about the BADI to use.

  • Reading XML file using BAPI and then uploading that xml file data into SAP

    I am getting a xml file from Java server. I need to take
    data from this file using BAPI and need to upload into SAP using SAP.
    Please tell me how to read XML files using BAPI's.

    <b>SDIXML_DATA_TO_DOM</b> Convert SAP data (elementary/structured/table types) into DOM (XML
    <b>SDIXML_DOM_TO_XML</b>  Convert DOM (XML) into string of bytes that can be downloaded to PC or application server
    <b>SDIXML_DOM_TO_SCREEN</b> Display DOM (XML)
    <b>SDIXML_DOM_TO_DATA</b>
    data: it_table like t001 occurs 0.
    data: l_dom      TYPE REF TO IF_IXML_ELEMENT,
          m_document TYPE REF TO IF_IXML_DOCUMENT,
          g_ixml     TYPE REF TO IF_IXML,
          w_string   TYPE XSTRING,
          w_size     TYPE I,
          w_result   TYPE I,
          w_line     TYPE STRING,
          it_xml     TYPE DCXMLLINES,
          s_xml      like line of it_xml,
          w_rc       like sy-subrc.
    start-of-selection.
      select * from t001 into table it_table.
    end-of-selection.
    initialize iXML-Framework          ****
      write: / 'initialiazing iXML:'.
      class cl_ixml definition load.
      g_ixml = cl_ixml=>create( ).
      check not g_ixml is initial.
      write: 'ok'.
    create DOM from SAP data           ****
      write: / 'creating iXML doc:'.
      m_document = g_ixml->create_document( ).
      check not m_document is initial.
      write: 'ok'.
      write: / 'converting DATA TO DOM 1:'.
      CALL FUNCTION 'SDIXML_DATA_TO_DOM'
        EXPORTING
          NAME               = 'IT_TABLE'
          DATAOBJECT         = it_table[]
        IMPORTING
          DATA_AS_DOM        = l_dom
        CHANGING
          DOCUMENT           = m_document
        EXCEPTIONS
          ILLEGAL_NAME       = 1
          OTHERS             = 2.
      if sy-subrc = 0.  write  'ok'.
      else.             write: 'Err =', sy-subrc.
      endif.
      check not l_dom is initial.
      write: / 'appending DOM to iXML doc:'.
      w_rc = m_document->append_child( new_child = l_dom ).
      if w_rc is initial.  write  'ok'.
      else.                write: 'Err =', w_rc.
      endif.
    visualize iXML (DOM)               ****
      write: / 'displaying DOM:'.
      CALL FUNCTION 'SDIXML_DOM_TO_SCREEN'
        EXPORTING
          DOCUMENT          = m_document
        EXCEPTIONS
          NO_DOCUMENT       = 1
          OTHERS            = 2.
      if sy-subrc = 0.  write  'ok'.
      else.             write: 'Err =', sy-subrc.
      endif.
    convert DOM to XML doc (table)     ****
      write: / 'converting DOM TO XML:'.
      CALL FUNCTION 'SDIXML_DOM_TO_XML'
        EXPORTING
          DOCUMENT            = m_document
        PRETTY_PRINT        = ' '
        IMPORTING
          XML_AS_STRING       = w_string
          SIZE                = w_size
        TABLES
          XML_AS_TABLE        = it_xml
        EXCEPTIONS
          NO_DOCUMENT         = 1
          OTHERS              = 2.
      if sy-subrc = 0.   write  'ok'.
      else.              write: 'Err =', sy-subrc.
      endif.
      write: / 'XML as string of size:', w_size, / w_string.
      describe table it_xml lines w_result.
      write: / 'XML as table of', w_result, 'lines:'..
      loop at it_xml into s_xml.
        write s_xml.
      endloop.
      write: / 'end of processing'.
    end of code
    Hope this will be useful.
    regards
    vinod

  • Create Service entry sheet using BAPI in SAP

    Hi
    Experts,
    Scenario : SES will be created in third party system , once it created, txt file will be generated and placed in their server.We will be writing a program
    to pick that file and post SES in ECC using BAPI ( Idoc is not available to create SES i believe).
    I will be using BAPI_ENTRYSHEET_CREATE to create SES sheet but we dont have service masters and creating unplanned service entry sheet.
    I will be checking by passing the values manually in BAPI to create SES.
    I am passing PO no, line no and qty, value and other details to create SES.
    It is creating SES with only header data. it is not updating line item details.
    I am missing some parameters to be passed to create SES using BAPI I feel.
    I need your help to create SES using BAPI.
    What are the details to be passed to create SES in SAP using BAPI.
    Regards,
    Suresh.A

    Did you not search? Google has 3600 hits for BAPI_ENTRYSHEET_CREATE
    the second hit is a wiki from SCN with sample coding
    the third hit  has a link to a OSS note with a promising title 420334 - BAPI_ENTRYSHEET_CREATE: Model for creation

  • Cannot use user classes in webservices interface of appmodule custom method

    Hi,
    I need to expose an application module's custom method that uses user defined classes as parameters and return types as a web service interface. I have not been able to do that. Below are more details.
    In particular, I have an app module that has a client interface with a custom method that takes and returns a serializable Emp object (user defined classes/objects). I need to expose this app module as a web service through the use of a service interface.
    When i run the "Create Service Interface" wizard, under service custom methods (Create Service Interface Step 2 of 4 wizard), i don't see my custom method under "Available."
    In addition, the JDev message log says: Business Components: Method "yourCustomMethod(Emp):Emp" cannot be exposed via service interface because the return type "com.mypackage.Emp" is not supported.
    From what i understand by reading the docs below, it seems that in an application module's service interface (Webservice) you only can use simple data type or java.util.list or AttributeList (which is a wrapper for any viewRow). In other words, i cannot use my user defined object in the custom method parameters and return types.
    This seems to be an artificial limitation of webservice creation through the use of app module because one can use complex/user defined objects in methods of a java class and expose them through a webservice.
    I would appreciate if of the tooling PMs can make a well thought out comment.
    11.2.3 What You May Need to Know About Method Signatures on the Service Interface
    http://docs.oracle.com/cd/E12839_01/web.1111/b31974/bcextservices.htm#CJAEHFJD
    9.8.4 What You May Need to Know About Method Signatures on the Client Interface
    http://docs.oracle.com/cd/E12839_01/web.1111/b31974/bcservices.htm#CHDFHGII
    Thanks,
    AJ
    ps: I am using Build JDEVADF_11.1.1.5.0_GENERIC_110409.0025.6013.

    Hi,
    question 2 doesn't apply as the client interface is for Java access to public methods. For the Service Interface, the document lists the supported data types you can use in arguments and return values. To expose a custom methods, what about using a POJO that accesses ADF BC (using create root application module) and then expose your POJO as a JAWS service. This will allow you to expose the data queried from ADF BC through your custom classes.
    Frank

  • Using BAPI for calling transaction from NON-SAP system

    hi all,
    im new to BAPI , i m working in producton firm we r short of license of SAP, we have given few authourisations to our venders and  we also have implemented HR portal and we r having shortage of license in that too. so my question is that can we use BAPI to reduce the use of SAP on vendors side and also for HR portal? like by using non-sap system on vendors side and for portal we can resolve the issue of licenses..???
    if yes then i want to do it that will be good for my carrer point of view. plzz help me out and give me the simple solution on it. we can not afford to buy the licenses bcoz of financial issues..
    thanxx....

    Hi Nilesh,
    Depending on the Scenario you need to decide what BAPI you will use. what solution are you excepting?
    Regards
    Shital

  • Interface Using BAPI for Uploading shipment datas

    Can any1 send me the example code for Inbound Interface using BAPI for Uploading shipment datas.please kindly send me the programs which u using with BAPI

    Hi
    Except hiring (or new joinee) for all other actions you can use below Function Module.
    HR_INFOTYPE_OPERATION.
    ~~~Ganesh Kumar K.

  • How to get PO details from SAP to VB using BAPI control

    hi friends...
    My requirement is
    In VB(Visual basic)  i will enter PO number, for that PO number i want to fetch the data from SAP to VB.
    How to get this using BAPI Control in VB.
    From SAP point of view, i checked SWo1, there standard Object (PurchaseOrder)-Method GetDetail is there.
    but my doubt is how to pass the PO number to which parameter...
    i dono how to use that standard Object (PurchaseOrder) in VB...
    can you guide me plz..
    regards
    deva

    Hi,
    You need to get .NET connector and use this in your VB.
    h6.
    The SAP .NET Connector is a development environment that enables communication between the Microsoft. NET platform and SAP systems. This connector supports RFCs and Web services, and allows you to write different applications such as Web form, Windows form, or console applications in the Microsoft Visual Studio.Net. With the SAP .NET Connector, you can use all common programming languages, such as Visual Basic. NET, C#, or Managed C++.
    In short it will make your VB talk to SAP.
    http://www.service.sap.com/connectors
    Regards,
    Firoz.

  • How to header and item data of sales order using bapi interface

    hi friends,
       i am geetha, i having a problem like how to upload sales oder header and item data through va01 tcode using BAPI FUNCTION MODULES.
    i need bapi function modules for header adn item data  and brief explation on that , how to pass importing and tables  parameters to get exact output .
    regards
    geetha.

    Use : BAPI_SALESORDER_CREATEFROMDAT2
    Sales order: Create Sales Order
    Functionality
    You can use this method to create sales orders.
    You must enter at least sales order header data (via ORDER_HEADER_IN structure) and partner data (via the ORDER_PARTNERS table) as input parameters.
    Enter the item data via the ORDER_ITEMS_IN table. You can allocate item numbers manually, by filling in the relevant fields, or the system does it, according to the settings for Customizing, by leaving the relevant fields blank.
    If you have configurable items, you must enter the configuration data in the ORDER_CFGS_REF, ORDER_CFGS_INST, ORDER_CFGS_PART_OF and ORDER_CFGS_VALUE tables.
    Credit cards can be transferred via the BAPICCARD structure, on the one hand, data for card identification, on the other, data for a transaction which has taken place in an external system.
    Once you have created the sales order successfully, you will receive the document number (SALESDOCUMENT field). Any errors that may occur will be announced via the RETURN parameter.
    If no sales area has been created in the sales order header, then the system creates the sales area from the sold-to party or ship-to party, who has been entered in the partner table. If a clear sales area cannot be created, you will receive a system message, and the sales order will not be created.
    Notes
    1. Mandatory entries:
    ORDER_HEADER_IN : DOC_TYPE     Sales document type
                       SALES_ORG    Sales organization
                       DISTR_CHAN   Distribution channel
                       DIVISION     Division
    ORDER_PARTNERS..: PARTN_ROLE   Partner role, SP sold-to party
                       PARTN_NUMB   Customer number
    ORDER_ITEMS_IN..: MATERIAL     Material number
    2. Ship-to party:
    If no ship-to party is entered, use the following: Ship-to party =
    sold-to party.
    3. Commit control:
    The BAPI does not have a database commit. This means that the relevant application must leave the commit, in order that can be carried out on on the database. The BAPI BAPI_TRANSACTION_COMMIT is available for this.
    4. German key words:
    The following key words must be entered in German, independantly of
    the logon language:
    DOC_TYPE     Sales document type, for example: TA for standard order
    PARTN_ROLE   Partner role, for example: WE for ship-to party
    Further information
    You can find further information in the OSS. The note 93091 contains general information on the BAPIs in SD.
    Parameters
    SALESDOCUMENTIN
    ORDER_HEADER_IN
    ORDER_HEADER_INX
    SENDER
    BINARY_RELATIONSHIPTYPE
    INT_NUMBER_ASSIGNMENT
    BEHAVE_WHEN_ERROR
    LOGIC_SWITCH
    TESTRUN
    CONVERT
    SALESDOCUMENT
    RETURN
    ORDER_ITEMS_IN
    ORDER_ITEMS_INX
    ORDER_PARTNERS
    ORDER_SCHEDULES_IN
    ORDER_SCHEDULES_INX
    ORDER_CONDITIONS_IN
    ORDER_CONDITIONS_INX
    ORDER_CFGS_REF
    ORDER_CFGS_INST
    ORDER_CFGS_PART_OF
    ORDER_CFGS_VALUE
    ORDER_CFGS_BLOB
    ORDER_CFGS_VK
    ORDER_CFGS_REFINST
    ORDER_CCARD
    ORDER_TEXT
    ORDER_KEYS
    EXTENSIONIN
    PARTNERADDRESSES
    Exceptions
    Function Group
    2032

  • Using BAPI's in ABAP code

    Hi bapi Guru's,
    I am asked to use bapi's(Instead of BDC's) for data upload .I am not getting good documentation on 'USING BAPI's IN ABAP',Like Defining structures, and what are the FM's to be called like bapi_commit.
    Any Info is Appriciated.
    Regards
    satish

    Sorry Satish,
    Maybe this is going off topic a little, bit perhaps also its relevant as you have been asked to move from BDC's to BAPIs.
    Juan,
    When I talk about debugging, there are two levels to this:
    <b>1. Debugging by the programmer</b>
    In this case, how can it be easier to debug an error from a BAPI than from the screen?  For a sales order, for example, when you enter a delivery date of 01.01.2000 for an item, via BDC you will get an error message as the item is entered (something along the lines of delivery date is in the past), and you will see exactly the date you have entered, and if you don't understand the error, you can click on F1 and it will give you the long description of the error.  Via a BAPI, you would get the error message, and you MIGHT get the item number and the date in question.  But if you don't understand the error what do you do then?  Debug the BAPI itself?  You could, but isn't this a rather lengthy way to get to the root of the problem?  In general, any errors you get calling BAPIs/BDCs are errors with your master data, or breaking business rules, you shouldn't have to debug standard code to tell you whats going wrong, the application can tell you.
    <b>2. Debugging by the end user</b>
    When you implement a BAPI/BDC this will be related to an interface/automated transaction etc.  When its in production you will occassionally get errors (due to bad master data, not fully capturing all the business logic in your custom coding [it happens], technical issues etc.)  What do you do then?  In the case of BDC you can do nothing.  The error is recorded, and you can get end users to process the errors by stepping through the screens (which they already know how to use) and make corrections as required.  In the case of BAPIs, you have to record the error in a table or a file, then develop some kind of interface to display the errors, then develop some kind of process for re-processing the errors.  If the data used to call the BAPI is not correct then you also need to provide a facility for changing the data before reprocessing.  Normally you do none of this because its too much work and you end up having all errors coming back to the SAP team who have to debug and change table entries etc. to get it all to work.  I would not say that this makes BAPIs easier to debug.
    Oops, just realised my pasta is burning!!!
    Anyway, think I got my point across.  Not personal but feel quite strongly about this topic.  To me BDC's are still a relevant tool despite the push for Idocs/BAPIs.
    Cheers,
    Brad

Maybe you are looking for