Regarding Native SQL to access Oracle Data from SAP

Dear Gurus,
This query is regarding Native SQL.
Our database is Oracle and the client's database is also Oracle.
To access the data directly from the client's database(Oracle), can I use Native SQL commands?
Is there any disadvantage to use Native SQL?
If Native SQL can be used, can any one send me the code to access the data from Oracle?
Points will be rewarded.
Thanks & Regards,
Neeraj K.

The problem is always data integrity. Doing things this way you are bypassing any business logic. So for example if you are connecting to a SAP Oracle database. SAP will not support your SAP system as you are doing direct updates to the database. I would suppose that this would be the same for any other product using the Oracle database. If you are only reading data from the database then it should be fine. I would however always using API's to access/update data.
Regards

Similar Messages

  • Help Required -- Can we use SQL Query to READ data from SAP MDM Tables

    Hi All,
    Please help.........
    Can we use SQL Query to READ(No Creation/Updation/Deletion  just Read) Data from SAP MDM tables directly, without using MDM Syndicator.
    Or direct SQL access to SAP MDM tables is not possible. Only through MDM Syndicator can we export data.
    Thanks in Advance
    Regards

    All the tables you create in Repository comes under A2i_CM_Tables in Database named as your repository name. So the tables names are fields of table A2i_CM_Tables. Now i tried it but cant make it.
    Now, I dont think its possible to extract all fields in tables and there values using select query. May be pure sql guy can do that or not.
    But there is no relation of data extraction and syndicator. Data is viewed in Data Manager. and you can also store data in a file from DM also.
    BR,
    Alok

  • TIME_OUT when accessing Oracle table from SAP using native SQL

    Hi,
    I have a problem in one of my native SQL statement. It takes a long time accessing the table considering that the number of records to be retrieved is only small.
    Something happened on the Oracle system. But, stilll to be confirmed. Looking further at the issue, it seems that when the value in the where clause equated is a literal (meaning the value is not declared in DATA or CONSTANTS in the ABAP Program)
    Example
    1.
    EXEC.
    WHERE FIELD = '1'
    ENDEXEC.
    instead of
    2.
    CONSTANTS: c_1 value '1'.
    EXEC.
    WHERE FIELD = c_1
    ENDEXEC.
    i found that when the way of coding is same as Example 1, a time-out error occurs. But when in Example 2, no issue.
    Can someone explain this?
    Thanks!

    Repetitively asking the same question again and again is against the forum rules.
    Please post an explain of the SQL statement on the remote machine.
    Markus

  • Newbie blues: Oracle Sql Developer showing different data from Sqlplus.

    Newbie blues: Oracle Sql Developer showing different data from Sqlplus.
    First of all; it would be difficult to know less about Oracle than myself.
    I just installed a recent copy of the server and am running SQl Developer 3.2.20.10.
    I made a small test table , borrowed some pl sql code to add rows, then wrote code to delete some rows. Lots of fun.
    In SQL Developer “Select * from t1;” now shows 7 records, which seems right.
    I wanted other views of the data and so logged in from the command line using SQLPlus.
    The same code here shows the table prior to the delete, with 600 plus rows. Needless to say I’ve logged out and back in again, with no changes.
    No fun ! What am I not understanding here ?

    5e33d18c-3b32-48d4-82a7-676feeaa97c9 wrote:
    Newbie blues: Oracle Sql Developer showing different data from Sqlplus.
    First of all; it would be difficult to know less about Oracle than myself.
    I just installed a recent copy of the server and am running SQl Developer 3.2.20.10.
    I made a small test table , borrowed some pl sql code to add rows, then wrote code to delete some rows. Lots of fun.
    In SQL Developer “Select * from t1;” now shows 7 records, which seems right.
    I wanted other views of the data and so logged in from the command line using SQLPlus.
    The same code here shows the table prior to the delete, with 600 plus rows. Needless to say I’ve logged out and back in again, with no changes.
    No fun ! What am I not understanding here ?
    Others sessions never see uncommitted data
    > then wrote code to delete some rows. Lots of fun.
    did you ever actually issue COMMIT so other session can see the changed data?

  • How to Pull data from sap r/3 tables to oracle tables

    how to fetch data from sap r/3 tables & data pulled to oracle table .
    GIVE THE APPROPRITE ANSWER FOR THIS.
    THANKS IN ADVANCE.
    If it is useful for me , i am giving point.
    regards ,
    Navita
    Edited by: NAVITA YADAV on Mar 7, 2008 2:07 PM
    Edited by: NAVITA YADAV on Mar 7, 2008 2:08 PM

    You need to perform some native SQL to fetch data. Before doing this connection must be exists b/w your R/3 and Oracle server.
    Basis team will help you to have connection.
    Check the connection name in the table DBCON.
    Check the below code to handle native SQL.
      SELECT SINGLE  DBMS
               FROM  DBCON
               INTO  DBTYPE
               WHERE CON_NAME = DBS.
      IF DBTYPE = 'ORA'.
        TRY.
          EXEC SQL.
            CONNECT TO :dbs
          ENDEXEC.
    ERROR Handling for Native SQL *************
          IF SY-SUBRC <> 0.
            MESSAGE `Docusphere connection failed.` TYPE 'I'.
            EXIT.
          ENDIF.
      EXEC SQL PERFORMING loop_output.
        OPEN C1 FOR
        SELECT  UK1, UK7, uk6, uk9, uk22, uk23, uk25    "field names of Oracle table
        FROM IIS_DOCS_AP10D
        WHERE ( UK2 = 'ZFIINVOICE' OR UK2 = 'ZFIPAYREQ' )    AND
        UK19 = 'E'                                           AND
        UK20 IS NULL
      ENDEXEC.
          DO.
            CLEAR W_OUTPUT.
            EXEC SQL.
              FETCH NEXT C1 into :wa1-arc_doc_id, :wa1-bukrs, :wa1-belnr, :wa1-gjahr, :wa1-wi_id, :wa1-ARCH_METHOD, :wa1-barcd.
            ENDEXEC.
    enddo.
    Reward points if helpful.................

  • Migration data from SAP DB2 to Oracle 10g

    Hi , I am assigned to migrate data from SAP system which is using DB2 to Oracle 10g.I not very familiar with SAP. I hope someone can help me., especially for those familiar in SAP.
    Please help me.
    thanks
    jebatco

    Hello,
    just migrating a DB2 database to Oracle 10g might be an easy task. The Oracle Migration Workbench is the tool for such a migration:
    http://www.oracle.com/technology/tech/migration/workbench/index.html
    I have no idea about SAP, and that might complicate the picture. But there exist specialists for this task:
    Oracle Expertise in the SAP environment
    The Solution Center SAP Support and Service – located in Walldorf – offers SAP
    customers the following services:
    • Advanced Customer Services (ACS)
    • Performance Analysis and Tuning
    • Development of concepts for Backup/Restore/Recovery, and High Availability,
    Administration
    • Security concepts
    • Optimizing of ABAP/4 programs (performance improvement)
    • Migration service for customers, who want to use Oracle as the database for SAP
    applications (from Informix, MaxDB, DB2, or SQL Server to Oracle).
    • Migration services from “Oracle to Oracle” (e.g. Tru64 to HP_UX)
    • Integration-Products and –Services
    • Oracle Database: The Database of Choice for Deploying SAP Solutions
    This is taken from http://www.oracle.com/newsletters/sap/docs/ora4sap-db-of-choice.090213.pdf
    Best regards
    Wolfgang

  • Migrating data from SAP BW to Oracle

    We have a requirement where the exisiting data from SAP BW needs to be migrated into Oracle. What are some of the major differences that we should keep in mind when migrating this data. Our first task is to generate the data model in Oracle. Can we use a tool such as SQL Data Modeler or ERwin to derive the logical model from SAP and use it to build the physical model in Oracle? Would this be possible? Can you share your experiences in building data models for data migration?

    This is a very specialized area you are looking at. My recommendation is that you look at SAP sites on Oracle.com for assistance. There is also a SAP Migration white paper you can read and the Oracle/SAP site.
    Regards
    Sue

  • Accessing External Data from SharePoint 2010

    I want to access external data from my SharePoint site.
    I'm told that I need to follow these two articles.
    http://msdn.microsoft.com/en-us/library/ff953161.aspx
    http://msdn.microsoft.com/en-us/library/ff625800.aspx
    I followed the first article but I get this error when I open the external list in my SharePoint site:
    "Unable to display this Web Part. To troubleshoot the problem, open this Web page in a Microsoft SharePoint Foundation-compatible HTML editor such as Microsoft SharePoint Designer. If the problem persists, contact your Web server administrator."
    I don't know how to write a custom code
    BTW I have installed PowerPivot on my SharePoint server.
    Can someone please help me? I need to do this very quickly.

    Hi,
    Can you please elaborate whether the data you are getting is from excel file or from database.
    1. If you are populating it from excel , then you can use the Excel service, Power pivot etc mechanism.
    2. If you are getting it from SQL database then you can use BCS service application and use the OOTB external list and content type to display the same in your home page.
    Links of artcles are given below.
    http://www.concurrency.com/blog/accessing-external-data-using-business-connectivity-services-in-sharepoint-2010/
    http://msdn.microsoft.com/en-us/library/ff677562(v=office.14).aspx
    Hope this will help.
    Thanks and Regards, -- Santanu Kumar Choudhury ----- SharePoint 2007/10/13 Developer

  • Unable to access the data from Data Management Gateway: Query timeout expired

    Hi,
    Since 2-3 days the data refresh is failing on our PowerBI site. I checked below:
    1. The gateway is in running status.
    2. Data source is also in ready status and test connection worked fine too.
    3. Below is the error in System Health -
    Failed to refresh the data source. An internal service error has occurred. Retry the operation at a later time. If the problem persists, contact Microsoft support for further assistance.        
    Error code: 4025
    4. Below is the error in Event Viewer.
    Unable to access the data from Data Management Gateway: Query timeout expired. Please check 1) whether the data source is available 2) whether the gateway on-premises service is running using Windows Event Logs.
    5. This is the correlational id for latest refresh failure
    is
    f9030dd8-af4c-4225-8674-50ce85a770d0
    6.
    Refresh History error is –
    Errors in the high-level relational engine. The following exception occurred while the managed IDataReader interface was being used: The operation has timed out. Errors in the high-level relational engine. The following exception occurred while the
    managed IDataReader interface was being used: Query timeout expired. 
    Any idea what could have went wrong suddenly, everything was working fine from last 1 month.
    Thanks,
    Richa

    Never mind, figured out there was a lock on SQL table which caused all the problems. Once I released the lock it PowerPivot refresh started working fine.
    Thanks.

  • How to get purchasing data from SAP R/3 to OWB (Oracle warehouse builder).

    Hi,
    My name is Pavan Tata. I work as a SAP BW developer. Here is the situation at my client place. Client decided to retire BW system and wants to replace with OWB(Oracle warehouse). In all this currently we have purhchasing application in BW production system and wants to move this application to OWB for the same type of reporting what they are getting currently.
    Here is my question:
    How to get purchasing data from SAP R/3 to OWB(Warehouse) with initial full loads and deltas mechanism in the same way as we do in BW.
    Please help on this, also send me any documentation about this if you have.
    Thanks,
    Pavan.

    Hello,
    here is a short report which converts S012 entries to strings with separator semicolon. Perhaps this will help you?
    Regards
    Walter Habich
    REPORT habitest2 LINE-SIZE 255.
    TYPES:
      strtab_t TYPE TABLE OF string.
    CONSTANTS:
      separator VALUE ';'.
    DATA:
      it_s012 LIKE s012 OCCURS 0,
      wa_s012 LIKE s012,
      strtab TYPE strtab_t,
      strele TYPE string.
    SELECT * FROM s012 INTO TABLE it_s012 UP TO 100 ROWS.
    PERFORM data_to_string
      TABLES
        strtab
      USING
        'S012'. "requires it_s012 and wa_s012
    LOOP AT strtab INTO strele.
      WRITE: / strele.
    ENDLOOP.
    *&      Form  data_to_string
    FORM data_to_string TABLES strtab TYPE strtab_t
                        USING  ittab TYPE any.
      DATA:
        h_zaehler TYPE i,
        line_str TYPE string,
        l_tabellenname(10) TYPE c,
        l_arbeitsbereichsname(10) TYPE c,
        h_string TYPE string,
        h_char(255) TYPE c.
      FIELD-SYMBOLS: <l_tabelle> TYPE ANY TABLE,
                     <l_arbeits> TYPE ANY,
                     <feldzeiger> TYPE ANY.
      CLEAR strtab.
      CONCATENATE 'IT_' ittab INTO l_tabellenname.
      ASSIGN (l_tabellenname) TO <l_tabelle>.
      CONCATENATE 'WA_' ittab INTO l_arbeitsbereichsname.
      ASSIGN (l_arbeitsbereichsname) TO <l_arbeits>.
      LOOP AT <l_tabelle> INTO <l_arbeits>.
        CLEAR: h_zaehler, line_str.
        line_str = ittab.
        DO.
          ADD 1 TO h_zaehler.
          ASSIGN COMPONENT h_zaehler OF
            STRUCTURE <l_arbeits> TO <feldzeiger>.
          IF sy-subrc <> 0. EXIT. ENDIF.
          WRITE <feldzeiger> TO h_char LEFT-JUSTIFIED.          "#EC *
          h_string = h_char.
          CONCATENATE line_str separator h_string INTO line_str.
        ENDDO.
        APPEND line_str TO strtab.
      ENDLOOP.
    ENDFORM.                    "data_to_string

  • Transfer Of Data from Sap to Oracle with the help of Enterprise Services.

    Hello,
    We want to transfer data from Sap to Oracle using standard Enterprise Services.Some fields were not available in the existing standard Enterprise Services,so we have enhanced the existing Services by writing code inside BADI available with Enterprise Services.Rest of the fields we have mapped with the existing fields available in standard Enterprise Services.But,the Oracle people want to fetch all data from Sap without entering any input as a mandatory field in the Enterprise Services.The existing standard Enterprise Services require to enter any field as mandatory and are not accepting the range in input for multiple records.e.g.All enterprise Services related to Sales Orders are displaying only one sales Order.We have searched all Enterprise Services for Sales Order(related to reading of data),but not able to find service which would display mutiple records without entering any input.ECC_SALESORDER009QR is the only service which is displaying multiple records without entering any input,but the required fields are not available in this service.So,kindly suggest what we need to do further.
    1.Should we go for customization of services completely,so that it would fulfil our requirement.
    2.Are there  standard Enterprise Services exists which would we give us data in range(all records).
    If they exists,please specify the names of Services for reading Purchase Order,Production Order,BOM etc.
    Thanks & Regards,
    Divya.

    Hi Vaibhav,
    Let me tell you the objective in detail.
    Objective.
    To develop a package solution which will work as a bridge between Oracle APS and SAP system so that customers using SAP will be able to use advantages of Oracle APS for their planning needs.
    This will consist of following major components:
    OA Templates is an Oracle utility to load data from any legacy system to Oracle APS using standard flat files.
    Oracle has developed an Application Integration Architecture which is a standard architecture used for integration of Oracle products with other systems.
    Enterprise services is an SAP utility to communicate with SAP.
    AIA canonicals are standard canonicals developed by Oracle where we have to map data fields from destination system (Oracle APS) and source system (SAP)
    Fusion middleware is being used to develop application interfaces following AIA standards.
    Tasks at stake:
    Mapping of Oracle APS fields and SAP Enterprise Service fields to AIA canonicals
    Technical work of developing middleware using Oracle Fusion
    From Sap side,we have to map fields which we have received from Oracle with the help of Enterprise Services,rest  consumption of these services is done by Oracle guys.So,suggest is there enterprise services available which would give us multiple records .
    Thanks & Regards,
    Divya.

  • Transfer data from SAP TABLES to a SQL table

    Hi,
    I need to transfer data from SAP tables to a SQL table. Please suggest the best way as well as the steps please.
    Regards,
    Kamlesh

    Hi
    Step 1: Create an entry for the External database in DBCON table using Trxn: DBCA.
    Field Name Description Value (For: E.g.:)
    CON_NAME Logical name
    for database con RAJ
    DBMS Database system MSS
    USER_NAME Database user <username>
    PASSWORD Password for setting up
    the connection
    to the database <pwd>/<pwd>
    CON_ENV Database-specific MSSQL_SERVER=depotserver MSSQL_DBNAME=HOF_INDORE
    DB_RECO Availability type for an open database connect
    Then, you can define internal table and code the following way:
    DATA: BEGIN OF wa,
    c_locid(3),
    c_locname(50),
    c_locstate(5),
    END OF wa.
    EXEC SQL.
    CONNECT TO 'RAJ' AS 'V'
    ENDEXEC.
    EXEC SQL.
    SET CONNECTION 'V'
    ENDEXEC.
    < Populate SAP data into an internal table >
    Loop on itab.
    EXEC SQL.
    < code here for populating data into MS-SQL Server table>
    ENDEXEC.
    Endloop.
    Regards,
    Raj

  • BAPI name to access employee data from systems like CSS, ISP GTP etc

    Hi All,
    Could you please suggest which BAPIs we need to use to access employee data from systems like CSS, ISP GTP etc
    Regards,
    Poonam
    Moderator message: Welcome to SCN!
    Moderator message: please do more research before asking, show what you have done yourself when asking.
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers]
    Edited by: Thomas Zloch on May 20, 2011 2:09 PM

    Hi All,
    Could you please suggest which BAPIs we need to use to access employee data from systems like CSS, ISP GTP etc
    Regards,
    Poonam
    Moderator message: Welcome to SCN!
    Moderator message: please do more research before asking, show what you have done yourself when asking.
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers]
    Edited by: Thomas Zloch on May 20, 2011 2:09 PM

  • How to access Sybase IQ data from SAP BW

    Hi,
    I read from Sybase website that we can access Sybase IQ data from SAP BW using Remote Cube through JDBC driver.
    Is there any documentation on how to configure that?
    Thanks in advance for your help.
    Our BW version is 7.01
    Sybase IQ is 15.4
    Thanks,
    CH

    Hi,
    The two files that are created are one is Control File ( will save as filename_s ) and other is data file. The control file will give you the details of your fields in your Infospoke
    regards
    Srini
    Message was edited by:
            Srinivas

  • Catalog Browser for iPhone (Accessing BI data from iPhone)

    Hi All,
       There is a prototype from innovative centre called "Catalog Browser for iPhone" which is used for accessing BI data from iPhone. Do anyone have any idea if this is ever productized for sale by SAP??
       Is there any other approach for accessing BI data from iPhone? Any help will be highly appreciable.
    Thanks,
    Raja Sekhar K

    Hello Damondhar,
    I agree with Mr. Villalba, you should use the information brodcaster to broadcast precalucated views or workbooks to Knowledge Management in the portal. This can be done by events, e.g monthly. Your external users will then have accees to the directory in which the reports are saved (through KM iviews).
    Have you read on help.sap.com,
    http://help.sap.com/saphelp_nw2004s/helpdata/en/index.htm -> SAP Netweaver by Key Capability -> Information Integration -> Information integration .. -> Business Intelligence -> BI Suite: Business Explorer ->  Integration of BI Content in Portal
    And
    BEx Web Application or Query As Document or Link in KM, http://help.sap.com/saphelp_nw2004s/helpdata/en/bc/7efa40dd14f06fe10000000a1550b0/content.htm
    Best regards,
    Jørgen Ruud

Maybe you are looking for

  • How do I convert this Applet to launch from a JFrame instead??

       A simple program where the user can sketch curves and shapes in a    variety of colors on a variety of background colors.  The user selects    a drawing color form a pop-up menu at the top of the    applet.  If the user clicks "Set Background", th

  • How do i get my tool bar  back on the screen

    How do I get my tool bar back on the bottom of my screen?

  • Windows 7 32bit - will not load on warm boot.

    I have the same problem on two PCs. They are both HP Workstations xw4600. I have the latest BIOS (786F3 1.22 A) and have tried with the older BIOS as well before upgrading. They will not start Windows 7 with a warm boot (restart). They just repeatedl

  • Appletv only showing pink music icon

    I'm new to Appletv (today) and my tv screen will only show an image of the unit plus a cable and the pink music icon. I can't get back to the menu so can't do anything. Am i stuck until i buy a micro usb cable? If so I'm not happy. Can anyone help wi

  • Master Data is loadable in DSO with Delta Update?

    Hi! 1) It is possible to load data from Master Data Datasource to a DSO in DELTA MODE and after (always in DELTA MODE) into an InfoObject? In other words: Datasource for Master Data (SAP ECC) --> DSO (SAP BI) --> InfoObject (SAP BI) [ALL IN DELTA MOD