cancel
Showing results for 
Search instead for 
Did you mean: 

Connecting External database with DBCON with SAP.Net Connector

former_member364916
Discoverer
0 Kudos

Hi Experts,

We have a scenario that requires to read data from External Database (e.g. Sybase IQ) through SAP and .Net Connector.  A DBCON configuration already setup and verified connecting to the External Database.  However, we are stilling missing the link to invoke query data from selected DBCON.  After some research, I could only found solution to get data from DBCON thru ABAP program with this reference. http://scn.sap.com/docs/DOC-28819

Is it possible to have same operation SAP .Net Connector?

   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.

Thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

MarkusTolksdorf
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Seungkwon,

you are trying to access the DB directly from ABAP with that code and not using NCo that then is delegating a request to the DB via the corresponding ADO .NET driver. With that approach you would use CALL <function> DESTINATION <dest> to call the function module in the .NET server, which then calls the SQL queries.

Best regards,

Markus