Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

fetch multiple records using Native SQL

Former Member
0 Kudos

Hello All,

I am trying to fetch data from an external database which is an oracle sysrtem.

I am currenty using cursor method to fetch the data.

The "fetch next cursor1" only bring 1 record at a time. And it is taking more than 20 mins to bring 1 record, it seems the table i am fetching has more than 12 million records.

Can someone please answer these 2 questions:

1) If is have oracle commands to query their tables, can i use them directly between the EXEC SQL   and  ENDEXEC.

   When i put a semicolon its giving error. Oracle statements end with semicolon.

2) There must be a way of fetching a set of records at one go from external system. Does anyone know the technique.

I appreciate your help.

1 REPLY 1

rosenberg_eitan
Active Contributor
0 Kudos

Hi,

Check if this is useful in your case.

See here

I am using there:

cl_sql_connection

cl_sql_statement

cl_sql_result_set

cx_sql_exception

Regards.