This website is not affiliated with, sponsored by, or approved by SAP AG.

Connecting to external database

Development (ABAP Development WorkBench, ABAP/4 programming)

Moderators: Snowy, thx4allthefish, YuriT, Gothmog

Connecting to external database

Postby Jan20 » Thu Feb 27, 2014 4:24 pm

Hello Experts,

My requirement is to connect to an external oracle system(on the same network) through ABAP to pull / push some data.
Is there any way we can connect to external database using ABAP?
Please suggest.
Jan20
 
Posts: 122
Joined: Mon Apr 10, 2006 10:46 am

Re: Connecting to external database

Postby Gothmog » Fri Feb 28, 2014 4:31 am

I think you can create a database connection in transaction DBCO, and then use EXECSQL on this database.
Have a look at the help on EXEC SQL - CONNECT for more details and an example.
68 74 74 70 3a 2f 2f 74 69 6e 79 75 72 6c 2e 63 6f 6d 2f 62 64 6f 37 6d 77 67
Gothmog
 
Posts: 1941
Joined: Wed Sep 12, 2007 4:46 am
Location: Probably not home

Re: Connecting to external database

Postby Jan20 » Fri Feb 28, 2014 11:40 am

Thank you for your response.

I did create an entry in DBCO and when i ran the report ADBC_TEST_CONNECTION to test the connection i get following message.

Could not open connection MYCONNECTION .
sql error 12,514 occured:
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor

Please suggest on what are other thing that i should be taking care of.

Thanks
Jan20
 
Posts: 122
Joined: Mon Apr 10, 2006 10:46 am

Re: Connecting to external database

Postby Gothmog » Mon Mar 03, 2014 4:22 am

There may be some action needed on the Oracle side - have a look here: http://scn.sap.com/docs/DOC-44814
68 74 74 70 3a 2f 2f 74 69 6e 79 75 72 6c 2e 63 6f 6d 2f 62 64 6f 37 6d 77 67
Gothmog
 
Posts: 1941
Joined: Wed Sep 12, 2007 4:46 am
Location: Probably not home

Re: Connecting to external database

Postby Jan20 » Mon Mar 03, 2014 10:14 am

Thanks much. I am able to connect to the external database now.
Jan20
 
Posts: 122
Joined: Mon Apr 10, 2006 10:46 am


Return to ABAP

Who is online

Users browsing this forum: No registered users and 6 guests





loading...


This website is not affiliated with, sponsored by, or approved by SAP AG.