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

Similar Messages

  • How to upload the  data into SAP R/3 System

    I have a scenario to  upload the flat file data into SAP R/3 System.
    I will describe my complete scenario here so that it will be better understanding for you to suggest the solution.
    The  segments that relevant for the upload of customer master data, namely
    HD : Header Segment
    PF  : Partner Function Segment
    OP : Output Segment
    TX : Tax Segment
    CR : Credit Segment
    CT : Customer Text Segment

    I think you can achieve this with IDOC creation. If it is so follow the steps below.
    Basic Type:
    Basic IDoc type defines the structure and format of the business document that is to be exchanged between two systems.
    Segments:
    Segments form the basic building blocks of an IDoc type and are used to store the actual datta. A segment type is the name of a segment and is independent of the SAP elease. A segment definition is the release-specific name of a segment.
    Steps in creating Segments:
    T.Code WE31
    Enter the name for your segment type and click on the create icon.
    Type the Short text.
    Enter the variable names and data elements.
    Save and Go back.
    Go to Edit -> Set Release.
    Repeat the steps to create more segments.
    IDOC TYPE:
    Business data is exchanged with an external system using the IDoc Interface.
    IDoc types (Special Structures) An IDoc type is defined through its permitted segments. Segments can be dependent on each other (parent and child segments). The IDoc interface can check for each IDoc whether thhe segments contained are compatible with thhe definitiion of its type. This systax check is activated or deactivated in the Partner Profiles.
    Steps in creating IDoc Type:
    T.Code WE30 to create IDoc Type.
    Enter the Object Name, Select Basic Type and click Create Icon
    Select the create new option and enter a description for your basic IDOC type and press enter
    Select the IDoc name and click Create icon
    The system prompts us to enter a segment type and its attributes
    Choose the appropriate values and press enter
    The system transfers the name of the segment type to the IDoc editor.
    Follow these steps to add more number of segments to Parent or as Parent-child relation.
    Save it and go back.
    Go to Edit -> Set Release.
    Message Type:
    Steps in Creating Message Type:
    T.Code WE81.
    change the details from Display mode to Change mode
    After selection, the system will give this message "The table is cross client (See help for further info)". Press enter.
    Click New Entries to create new Message Type.
    Fill details
    Save it and go back.
    Assign Message Type to IDoc Type:
    T.Code WE82
    Change the details from Display mode to change mode.
    After selection, the system will give this message "The table is cross client (See help for further info)". Press enter.
    Click New Entries to create new Message Type.
    Fill details
    Save it and go back.
    Reward Points if useful.

  • How to upload the data to SAP-DMS(Document Management System)

    Dear sir,
    How to upload the data to SAP-DMS (Document Management System) please give me the code for this .ex for (excel format or tab  deliminated) to sap system through BAPI i have to pass.
    regards
    R M Patil

    Hi,
    May be following link may help you.
    /thread/315373 [original link is broken]
    /message/205534#205534 [original link is broken]
    Thanks,
    Sree.

  • How to retrieve the data from SAP database.

    Hi Pals,
    How to retrieve data from SAP R/3 System to my third party software. I will make my query little bit more clear. There is a list of assets entered and stored in the SAP system. For example 3 mobile phones.
    1) Mobile 1- Nokia
    2) Mobile 2 - Samsung
    3) Mobile 3 u2013 Sony
    Now think I do not know what all assets is there. I have to retrieve the data and get it on my third party software. Just display the list of assets. Lets say SAP XI is also there. Now how will I map it and get the details.
    Please give me step by step method.
    N.B: Just to read the data from SAP database.
    Please make the flow clear step by step.
    Thanking you
    AK

    Hi,
    You can use RFC or ABAP Proxy to make synchronous call with SAP.
    Under RFC or ABAP Proxy Program you can get the data from SAP tables. Direct access to SAP Database is not preferrable even if its possible.
    The better way to go for RFC or PROXY.
    You will send the request from Third party system and the it will be as input parameters from RFC/ Proxy it will response based on it.
    This got it all..
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/5474f19e-0701-0010-4eaa-97c4f78dbf9b
    /people/siva.maranani/blog/2005/09/03/invoke-webservices-using-sapxi
    /people/stefan.grube/blog/2006/09/21/using-the-soap-inbound-channel-of-the-integration-engine
    /people/arpit.seth/blog/2005/06/27/rfc-scenario-using-bpm--starter-kit - File to RFC
    HTTP to RFC - A Starter Kit
    /people/community.user/blog/2006/12/12/http-to-rfc--a-starter-kit
    Refer
    Thanks
    Swarup
    Edited by: Swarup Sawant on Jun 4, 2008 9:32 AM

  • How to reload archived data into SAP database for object FI_DOCUMNT

    Hi..could any one plz let me know how can i reload the archived data  which is on third party storage into sap database back. The archived data is related to FI_DOCUMNT. We don't have the Reload program for this object. The requirement is : Some of the FI documents are archived before being cleared. So, we want to reload the archived data back to SAP database and then do some modifications.
    Please tell me how this is possible..thanks a lot in advance.
    It's urgent.
    Thanks,
    Shamim

    Thanks Mylene. I've already gone through the same note..i was just looking out for the new standard program or any one have created any new program for the same. I think it's better we must wait for SAP to launch its reload program or else it's not possible to reload the archived data for this object.
    Thanks
    Shamim

  • Uploading the file into sap ( fields are seprerated by ' | '.

    Hi All,
    Plz let me know how to upload the file into sap in which the fields are separated by the symbol ' | '
    sample file format
    Material|Oracle_Item_type
    (89034)|PFG
    001069-000-97|BTF/BTS
    001070-000-97|SRV PTS
    001074-000-00|SRV PTS
    001086-000-97|SRV PTS
    001143-000-97|SRV PTS
    001176-000-97|SRV PTS
    001197-000-97|SRV PTS

    data: gt_txtar TYPE truxs_t_text_data.
    CALL FUNCTION 'SAP_CONVERT_TO_TEX_FORMAT'
              EXPORTING
                i_field_seperator    = ' | '
              TABLES
                i_tab_sap_data       = itab
              CHANGING
                i_tab_converted_data = gt_txtar.
    CONCATENATE '/usr/sap/tmp/file.txt' INTO lv_dwnfile.
    OPEN DATASET lv_dwnfile FOR OUTPUT IN TEXT MODE ENCODING UTF-8 .
    loop at gt_txtar.
    TRANSFER gt_txtar TO lv_dwnfile.
    endloop.
    CLOSE DATASET lv_dwnfile .
    Regards
    Sathar
    Edited by: Sathar RA on Sep 1, 2008 9:47 AM

  • How to retrieve the data from SAP-BAPI by using VB Code

    Hi ,
    I am new to BAPI.
    V have created an application in Visual Basic with the following fields
    EmpNo , EmpName, Addr1, Addr2, City and Phone (Only for Test)
    We have written the code for SAVING the data into SAP. Already we have
    constructed a table with the respective fields in SAP.
    For that we ourself created our own BAPI Structure / Function Group /
    Function Module/ Business Object - RELEASED related elements.
    1)Established the connection successfully.
    2)Stored the data into SAP Successfully and v r in need of
    3)HOW TO RETRIEVE THE DATA FROM SAP (USING GETLIST.....GETDETAIL....)
    Following is the code :
    'BAPI Structure  : ZBAPIEMP
    'Function Group  : ZBAPIEMP
    'Function Module : ZBAPI_EMP_CREATEFROMDATA
    'Business Object : ZBAPIEMP
    'Function Module : ZBAPI_EMP_GETLIST
    Dim bapictrl As Object
    Dim oconnection As Object
    Dim boEmp As Object
    Dim oZEmp_Header As Object
    Dim oImpStruct As Object
    Dim oExpStruct As Object
    Dim oreturn As Object
    Dim x As String
    Private Sub Form_Load()
    Set bapictrl = CreateObject("SAP.BAPI.1")
    Set oconnection = bapictrl.Connection
    oconnection.logon
    Set boEmp = bapictrl.GetSAPObject("ZBAPIEMP")
    Set oZEmp_Header = bapictrl.DimAs(boEmp, "CreateFromData", "EmployeeHeader")
    Set oImpStruct = bapictrl.DimAs(boEmp, "GetList", "EmployeeDispStruct")
    End Sub
    Private Sub cmdSave_Click()
        oZEmp_Header.Value("EMPNO") = txtEmpNo.Text
        oZEmp_Header.Value("EMPNAME") = txtEmpName.Text
        oZEmp_Header.Value("ADDR1") = txtAddr1.Text
        oZEmp_Header.Value("ADDR2") = txtAddr2.Text
        oZEmp_Header.Value("CITY") = txtCity.Text
        oZEmp_Header.Value("PHONE") = txtPhone.Text
        boEmp.CreateFromData EmployeeHeader:=oZEmp_Header, Return:=oreturn
        x = oreturn.Value("Message")
        If x = "" Then
            MsgBox "Transaction Completed!..."
        Else
            MsgBox x
        End If
    End Sub
    Private Sub cmdView_Click()
    End Sub
    COULD ANYBODY GUIDE ME, HOW TO RETRIEVE THE DATA FROM BAPI, FOR THE WRITTEN CODE.

    I didn't seen any other answers but here's how it's been done previously in our organization for a custom BAPI. In this example, we give material and language to return the part description. It's not specific to your project but may give you ideas..
    -Tim
    Option Compare Database
    Dim SAPLOGIN As Boolean
    Dim FunctionCtrl As Object
    Dim SapConnection As Object
    Sub SAPLOGOUT()
    On Error GoTo LogoutFehler
        SapConnection.logoff
        SAPLOGIN = False
    Exit Sub
    LogoutFehler:
        If Err.Number = 91 Then
            Exit Sub
        Else
            MsgBox Err.Description, vbCritical, "Fehler-Nr." & CStr(Err.Number) & " bei SAP-Logout"
        End If
    End Sub
    Function SAPLOG() As Boolean
    'Verbindungsobjekt setzen (Property von FunctionCtrl)
       Set FunctionCtrl = CreateObject("SAP.Functions")
       Set SapConnection = FunctionCtrl.Connection
    'Logon mit Initialwerten
       SapConnection.Client = "010"
       SapConnection.Language = "EN"
       SapConnection.System = "PR1"
       SapConnection.SystemNumber = "00"
       'SapConnection.Password = ""
       SapConnection.GroupName = "PR1"
       SapConnection.HostName = "168.9.25.120"
       SapConnection.MessageServer = "168.9.25.120"
         If SapConnection.Logon(0, False) <> True Then  'Logon mit Dialog
             Set SapConnection = Nothing
             DoCmd.Hourglass False
             MsgBox "No connection to SAP R/3 !"
             SAPLOGIN = False
             SAPLOG = False
             Exit Function
          End If
        SAPLOG = True
    End Function
    Function MatDescr(MatNr As String)
    Dim func1 As Object
    Dim row As Object, X As Integer, ErsteNr As String
    Dim DatensatzZähler As Long
    Dim RowField(1 To 50, 0 To 1) As String, RowLine As Long
        If Not SAPLOGIN Then
            If Not SAPLOG() Then
                MsgBox "No connection  to SAP !", 16
                SAPLOGOUT
                Exit Function
            End If
        End If
    ' Instanziieren des Function-Objektes
    Set func1 = FunctionCtrl.Add("Z_BAPI_READ_MAKT")
    ' Export-Paramter definieren
    func1.exports("MATNR") = MatNr
    func1.exports("SPRAS") = "EN"
    DoEvents
    If Not func1.call Then
        If func1.exception <> "" Then
            MsgBox "Communication Error with RFC " & func1.exception
        End If
        DoCmd.Hourglass False
        SAPLOGOUT
        Exit Function
    Else
      MatDescr = func1.imports("MAKTX")
    End If
    If MatDescr = "" Then
        MatDescr = "PART NO. NOT FOUND"
    End If
    End Function

  • How to write the data into EEPROM using Labview?

    How to write the data into EEPROM using Labview?

    You would need some sort of EEPROM programmer. Typically might
    communicate with it via serial. I don't know how you would do this in
    LV. You would need to have the command protocol for the programming
    device to start with.
    Doug De Clue
    gpibssx wrote in message news:<[email protected]>...
    > How to write the data into EEPROM using Labview?

  • How to uplaod the data into transaction IA01

    Hi All,
    I have tried to upload the data into transaction IA01 using direct input object 0470.
    But one structure for Service Package Overview tab is missing.Can anyone suggest on how we proceed about it,like is there any BAPI to upload the data.Because there are almost 150 fields that need to be uploaded into the transaction which has different tabs in it so it would be very difficult to handle with BDC's.
    Thanks and Regards,
    Shilpa

    Hi All,
    I have tried to upload the data into transaction IA01 using direct input object 0470.
    But one structure for Service Package Overview tab is missing.Can anyone suggest on how we proceed about it,like is there any BAPI to upload the data.Because there are almost 150 fields that need to be uploaded into the transaction which has different tabs in it so it would be very difficult to handle with BDC's.
    Thanks and Regards,
    Shilpa

  • Upload the data into interface

    HI Abapers,
    My requirement is that i want to upload the data into the transaction where for the header data there are n number of  item transactions , so my requirement is to select all the item  transactions that should be done in background, so i have written the code below but it is selectiong only the first row
    itd2[] = itd[].
    *icount = 1.
        LOOP AT itd2 INTO wa_itd2.
    icount = 1.
        CONCATENATE 'GWA_MTBAL-CHECK(' icount ')'  INTO w_fnam.
          PERFORM bdc_field       USING 'BDC_CURSOR'
                                  w_fnam.
          PERFORM bdc_field       USING w_fnam
            'X'.
          icount = icount + 1.
        ENDLOOP.
        PERFORM bdc_dynpro      USING 'SAPMZPP001_PRODORDCONF' '9010'.
        PERFORM bdc_field       USING 'BDC_OKCODE'
                                      '=GR'.
    Pls reply for any changes in code or any clarifications for this post.
    Thanks In advance.

    Hi thank you  for kind reply i need to create the entries  for CO Activity /Price planning .
    i have to upload data to KP26 which i have posted the fields ..
    i already cheked the function modules which you have been given .. it is not suitable ..
    Is there any ohter  BAPI is there ... le t me know ...
    regards
    purushotham.ineni

  • How to batch upload some data into SAP system?

    Hi All:
    I'm a SAP key user in our company, I want to know how to batch upload master data into SAP system? What t-code we can use for batch input?
    Thanks in advance!

    Hi,
    I think at least there are four methods for batch input which you can use in SAP system:
    Standard mass change t-code: for example, MM17 for mass change of material master data, you can find the mass change t-code under the relevant function module;
    T-code SCAT, you can use to record and generate the simple batch input template, it's easy to use for key user;
    T-code LSMW, it's another transaction to generate batch input template, it's often used at the beginning of SAP rollout;
    ABAP program, of course, ABAP is a universal tool for everything, you can use ABAP to generate a batch input program to upload data into SAP system as well.
    So you had better contact your SAP support department, help you to upload data!
    Good luck
    Tao

  • How to upload the data from excel(3 tabs) file to sap environment

    Hi all,
    This is Mahesh.
    how to upload the data from excel(3 tabs) file to sap environment (internal tables) while doing bdc.

    Hi,
    The FM 'ALSM_EXCEL_TO_INTERNAL_TABLE' makes it possible to load a worksheet into an internal table in ABAP.
    However, if you want to get the data from several worksheets, I think you are stuck with OLE access to your Excel Workbook...
    You can find a solution for 2 worksheets in this post :
    TO UPLOAD DATA FROM 2 EXCEL SHEETS INTO TWO INTERNAL TABLES
    I think you can easily modify it to handle any number of worksheets.
    Hope it helps !
    Best regards,
    Guillaume

  • How to maintain the data  into database table

    Hi,
    experts,
    how to maintain the data  into database table

    There are several ways to maintain data in the database
    1. Use table maintanance generator . You can create this using SE11 and data can be edited through SM30.
    2. Loginto  SE11 with the specified table and check the ATTRIBUTES tab. There you can set some parameters for maintaining the database. When you set Maintain database, you edit the data thorugh SE11 it self
    3. Through Se16 as well.
    4. A small abap program can do the above task as well.
    Thanks,
    Raj
    Edited by: Rajanya Kolavennu on Feb 5, 2008 8:33 PM

  • Can we use BAPI BAPI_ACC_DOCUMENT_POST to upload the vendor invoice?

    Hi,
    Can anybody tell me, can we use bapi BAPI_ACC_DOCUMENT_POST to upload the vender invoice?
    If yes, then which parameters we have to pass, and if no, then which is the other BAPI which is used for
    this purpose?
    Regards,
    Mrunal

    Hi Mrunal,
    Yes you can use BAPI_ACC_DOCUMENT_POST to upload vendor invoices.
    Parameters which are required to be passed are :
    Import tab :
    DOCUMENTHEADER: Mandatory fields for this specififed in documentation for this.
    Table tab:
    ACCOUNTGL: Enteries aganist GL account will be populated in this(check documentation for mandatory fields)
    ACCOUNTPAYABLE: Enteries aganist vendors will be populated in this(check documentation for mandatory fields)
    CURRENCYAMOUNT: in this currency amount aganist GL and vendor entries will specified.
    ITEMNO_ACC field will act as identifier as to amount belongs to which GL or vendor enteries.
    This much parameter are required to post vendor invoices.
    Regards,
    Brajvir

  • How to save the data to sap abap using Adobe Flex

    Hi Everybody......
    I am new to Adobe flex with sap abap.
          How to save the data in sap abap using Adobe Flex coding is Action Script and using RFC web service.
    Please give me any suggisions on that.
    Thank you
    Venkatesh V

    Hi Venkatesh,
    Try with folowing coding...
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"
         initialize="initApp()">
         <mx:Label x="10" y="23" text="Airline" width="90" id="lblAirline"/>
         <mx:TextInput x="108" y="21" id="txtAirline"/>
         <mx:Button x="10" y="49" label="Get Data" id="btnGetData" enabled="false" click="getData()"/>
         <mx:DataGrid x="10" y="97" id="dgFlightData" dataProvider="">
         </mx:DataGrid>
           <mx:Script>
              <![CDATA[
                   import mx.collections.ArrayCollection;
                   import mx.rpc.AbstractOperation;
                   import mx.rpc.events.FaultEvent;
                   import mx.rpc.soap.LoadEvent;
                   import mx.rpc.events.ResultEvent;
                   import mx.rpc.soap.WebService;
                   [Bindable] public var flightData:ArrayCollection;
        private var flightWS:WebService;
         private function initApp():void{
              flightWS = new WebService();
              flightWS.wsdl = "http://uscib20.wdf.sap.corp:50021/sap/bc/soap/wsdl11?services=ZGTEST&sap-client=000";
            flightWS.addEventListener(FaultEvent.FAULT,onWSError);
              flightWS.addEventListener(LoadEvent.LOAD,onWSDLLoaded);
             flightWS.addEventListener(ResultEvent.RESULT,onFlightWSGotResult);
              flightWS.loadWSDL();
    private function getData():void{
              var operation:AbstractOperation = flightWS.getOperation("ZGTEST");
              var input:Object = new Object();
              input.Airline = txtAirline.text.toUpperCase();
              operation.arguments = input;
              operation.send();
         private function onWSError  (event:FaultEvent):void{
         private function onWSDLLoaded(event:LoadEvent):void{
              btnGetData.enabled = true;
         private function onFlightWSGotResult(event:ResultEvent):void{
              flightData = event.result.SFLIGHT;
              ]]>
         </mx:Script>
    </mx:Application>
    Regards,
    Vinoth

Maybe you are looking for