|
Posted by laurenq uantrell on 09/17/05 20:02
I am trying to determine which of three stored procedure designs are
fastest in the Query Analyzer:
One query is a straight SELECT query with all desired rows and a dozen
(tblName.RowName = @param or @param = Null) filters in the WHERE
statement.
One query populates a #Temp table with the UniqueIDs from the results
of the SELECT query in the above example, then joins that #Temp table
to get the desired rows.
One query users EXEC sp_executesql @sql, @paramlist, @param
in which the @param has the dozen filters.
What I'm trying to determine is which is the fastest.
Each time I run the query in Query Analyzer it returns the same
recordset (duh!) but with much different Time Statistics.
Are the Time Statisticts THE HOLY QRAIL as far as determining which is
fastest, and what so I want to look at, the Vale or the Average? I
notice there are different numbers of bytse sen and bytes received for
each of the three queries.
Any illumination on this is appreciated.
lq
Navigation:
[Reply to this message]
|