PC Review Forums Newsgroups Microsoft DotNet Microsoft ADO .NET A query runs 10 times slower from a .NET application the from Query Analizer

Reply

A query runs 10 times slower from a .NET application the from Query Analizer

 
Thread Tools Rate Thread
Old 22-06-2006, 12:12 PM   #1
Boaz Ben-Porat
Guest
 
Posts: n/a
Default A query runs 10 times slower from a .NET application the from Query Analizer


Computer: 3.4 Ghz CPU, 1 GB RAM, 2003 Server

database : MS SqlServer 2000 Enterprise. ~ 10 GB database file. Largest
table in the database contains 11,000,000 records.

Framework: .NET 2.0

I try to run a query against the database, selecting aggregated data from
views based on the large table.
When executed from the Query Analizer, it takes 13 seconds.
When executed from a .NET application, it takes 140 seconds.

The database is well tuned (or else the query analizer would go slowly), so
I can't find the reason for this difference.

Any suggestion ?

TIA
Boaz Ben-Porat

Milestone Systems



  Reply With Quote
Old 22-06-2006, 03:28 PM   #2
Bryan
Guest
 
Posts: n/a
Default Re: A query runs 10 times slower from a .NET application the from Query Analizer

Boaz,

I'm not a DBA, but if you post the code your using to run the query,
maybe I, or someone else here will be able to pick out something...

- Bryan


Boaz Ben-Porat wrote:
> Computer: 3.4 Ghz CPU, 1 GB RAM, 2003 Server
>
> database : MS SqlServer 2000 Enterprise. ~ 10 GB database file. Largest
> table in the database contains 11,000,000 records.
>
> Framework: .NET 2.0
>
> I try to run a query against the database, selecting aggregated data from
> views based on the large table.
> When executed from the Query Analizer, it takes 13 seconds.
> When executed from a .NET application, it takes 140 seconds.
>
> The database is well tuned (or else the query analizer would go slowly), so
> I can't find the reason for this difference.


  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off