January 28, 2008 at 7:17 am
My initial query for a report returned 2.82 of data in 34509 rows and took 1:34. I removed some unneeded fields from the select and grouping statements and now it returns 1.22 mb in 16418 rows but still takes the same amount of time. Could some one please explain to me why the execution time did not decrease when I decreased the amount of data?
Thanks
Dean
January 28, 2008 at 7:50 am
Probably because most of the time is spent in martialing the rows of data, not particular columns.
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
January 28, 2008 at 7:57 am
Thanks, but the number of rows was cut in half and there was no reduction in execution time. so I'm still confused:unsure:
January 28, 2008 at 8:04 am
Sorry, I didn't read the whole post (again).
That is odd. Where are you measuring the time elapsed, the server or the client?
Have you looked at the execution plan? Maybe most of the cost is in a single operation that hasn't changed despite the other changes to the query.
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
January 28, 2008 at 9:40 am
I'm just looking at the clock in the bottom right corner of the Management Studio window. I highlighted the select statement in my sproc and then clicked Execute
January 28, 2008 at 10:50 am
That's elapsed time on the client then. Have you looked at the execution plans?
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply