Application Development Blog Posts
Learn and share on deeper, cross technology development topics such as integration and connectivity, automation, cloud extensibility, developing at scale, and security.
cancel
Showing results for 
Search instead for 
Did you mean: 
venkateswaran_k
Active Contributor

Scenario

In today's business scenario, at the time of SAP implementation, it is required that we need to fetch data from the customer's existing third party application.  For example the customer is having some websites where the enquiries are being stored. Or The company employees who are on tour log their requests for leave in the portal.  In such case we may have to provide an interface between their existing application to the upcoming SAP system.  It is possible that the system is using a differetn database altogather.  So in that situation how a connectivity is established between the SAP database and External Application database.

  1. First step is to provide the network / firewall / security related settings between these two servers. That is from the SAP ystem the designated database servers are accessible.
  2. In SAP system - configure the connection detail. Execute T-Code  DBCO
  3. Enter appropriate details as follows:
    • In the box, DB Connection, give any name of the connection. - the name in our SAP programs to connect to the oracle system.
    • In DBMS, choose the option ORA for oracle system.
    • In the user name box, give the name of the oracle system user. You will notice two boxes for DB password – one is the password box and the other one is the confirm password box. Give the password in both the boxes.
    • In Conn. Info box, give the name of the Oracle server – you may ask your database Administrator to get the name of the server
    • Check the check box Permanent to make the connection permanent and
    • Finally the connection limit as 5.
  4. Go to SE38 - to write a test program

   REPORT  ZSAP2ORACLE.
  data: l_record(20).

          * opening the connection to database
  EXEC SQL.
     CONNECT TO 'MYCONNECTION'
  ENDEXEC.*executing the select command
  EXEC SQL.
     SELECT ars_no into :l_record FROM arsdata
  ENDEXEC.*closing the connection
  EXEC SQL.
     DISCONNECT :'MYCONNECTION'
  ENDEXEC.
  WRITE: / l_record.

This should work and you should be able to fetch data from the external database.

7 Comments