Postby jpdomenge » Mon 15 Mar 2010 08:35

Hi all,

I was wodering how the method GetRecordCount is implemented to know the cost of using it (does it query the database and cache retrieved data ?).

In a same kind of question, what is the best way to retrieve data from an oracle database, for the moment i'm using UniDatareader and I fill dataset but I'm not sure it is the most efficient way. And if I use the method getRecordcount before filling a dataset, is the command executed twice ?

Posts: 12
Joined: Fri 12 Mar 2010 08:17

Postby StanislavK » Tue 16 Mar 2010 10:20

The GetRecordCount method executes a command like "select count(*) from (%your select command%)". Thus, an additional command is executed on the server, but the result set is not cached in the memory of your application.

As for the second question, the UniDataReader class should be the fastest tool for retrieving data from the server.
Devart Team
Posts: 1710
Joined: Thu 03 Dec 2009 10:48

Return to dotConnect Universal