Differences in execution times for a stored procedure

From: Vincent Keller (siliinvestor_at_hotmail.com)
Date: 10/04/04


Date: Mon, 4 Oct 2004 09:34:26 -0700

I am trying to execute a time-consuming stored procedure in my application.
When I run the stored procedure through Query Analyzer, it takes some time
but returns results in about 15-20 secs. However, when I run the same
procedure by using ExecuteScalar/ExecuteNonQuery it seems to take a lot more
time ( ~ 2-3 mins).

I have ensured that I am not keeping the connection open for a long time as
well as used Indexes where required but that hasn't helped a lot.

Are there some known performance differences in executing a query (stored
procedure) directly through Query Analyzer and through ADO.NET ?

Any recommendations for such a scenario to speed up query performance ?



Relevant Pages

  • RE: Differences in execution times for a stored procedure
    ... If OleDb, ... "Vincent Keller" wrote:> I am trying to execute a time-consuming stored procedure in my application. ... > Are there some known performance differences in executing a query directly through Query Analyzer and through ADO.NET? ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: ADO, SQLServer2000 and errors
    ... "Luigi" wrote in message ... > If I execute the stored procedure in Query Analyzer what happens, ...
    (microsoft.public.data.ado)
  • xp_sendmail
    ... I'm running sql 2000 and when I execute xp_sendmail with the parameters in ... query analyzer I get the following error: ... Could not find stored procedure 'xp_sendmail'. ...
    (microsoft.public.sqlserver.tools)
  • export stored procedure to excel
    ... creates a crosstab and I can see the results of it when I ... execute it in query analyzer like so: ...
    (microsoft.public.sqlserver.programming)
  • RE: SQL stored procedure executing twice
    ... I wasn't aware that DLookupwould execute the "domain" more than once. ... caused the stored procedure to execute twice. ... Dim stDocName As String ... My pass-thru query properties ...
    (microsoft.public.access.modulesdaovba)

Loading