What is the fastest way to pull data from an Oracle table?

  • Thread starter Thread starter Gummy
  • Start date Start date
G

Gummy

Hello,

I have a pretty large table (22,000 rows, 40 columns) that I need to return
to either a webpage (maybe a datagrid or just a table) or just spit out
directly to Excel. This table is coming from an Oracle database.

The code we are using now uses the Enterprise Library and using the
ExecuteDataSet method. I tried the ExecuteReader, but that didn't seem any
faster. When I use the ExecuteReader my assumption is that I still need to
get it into either a DataTable or DataSet in order to do anything with it. I
haven't found a real good and/or fast way to do that. I can do it, but I
don't image it is very optimized.

What I don't understand is that if I use a query tool, such as Toad or SQL
Navigator, I can pull the entire table in about 10 seconds. If I pull it
through .NET it can take as long as seven minutes. That is even if I just
iterate through the rows, not returning them to a page, just a running count
on my Immediate window. I guess there is much more overhead with .NET, but I
am surprised at such a big difference in time.

My guess is that the Enterprise Library may be slowing things down, but I
have no proof of that or any way to confirm those suspicions.

I would really appreciate any suggestions on getting this to work faster.

Thank you.

-G

p.s. We are using .NET 1.1
 
Hello,

I have a pretty large table (22,000 rows, 40 columns) that I need to return
to either a webpage (maybe a datagrid or just a table) or just spit out
directly to Excel. This table is coming from an Oracle database.

The code we are using now uses the Enterprise Library and using the
ExecuteDataSet method. I tried the ExecuteReader, but that didn't seem any
faster. When I use the ExecuteReader my assumption is that I still need to
get it into either a DataTable or DataSet in order to do anything with it. I
haven't found a real good and/or fast way to do that. I can do it, but I
don't image it is very optimized.

What I don't understand is that if I use a query tool, such as Toad or SQL
Navigator, I can pull the entire table in about 10 seconds. If I pull it
through .NET it can take as long as seven minutes. That is even if I just
iterate through the rows, not returning them to a page, just a running count
on my Immediate window. I guess there is much more overhead with .NET, but I
am surprised at such a big difference in time.

My guess is that the Enterprise Library may be slowing things down, but I
have no proof of that or any way to confirm those suspicions.

I would really appreciate any suggestions on getting this to work faster.

Thank you.

-G

p.s. We are using .NET 1.1

Hi,
Data Retrival using DataReader is the fasted method....
But according to your post it seems you are having problem with
datareader also...
try use oracles dataprovider.... developed by oracle
http://www.oracle.com/technology/tech/windows/odpnet/index.html

Thanks
Masudur
ww.kaz.com.bd
 
Back
Top