April 30, 2010 at 5:09 am
I had a table with 16 million records.Having good indexes and fragmentation. Hardware is good to support any query. But some queries taking lot off time. I had primary key defined on the table. When ever i execute any query it is going to keyloopup. Even i had added covering indexes, the keylookup is happening with clustered index. So, the data retrival is very slow. What i need to do avoid keylookup and retrive my data faster?
April 30, 2010 at 6:06 am
Without knowing the structure of your database or your query, we can't answer that question. Performance depends on too many things for us to blindly say "XYZ".
Post your query with some sample data and a mock setup of the table(s) and indexes in question.
April 30, 2010 at 8:19 am
I agree with Brandie.
I will add this though, if your index was truly covering, and the one used by the execution plan, you shouldn't get a key lookup. So it's either the wrong index, or it's not covering.
"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
April 30, 2010 at 8:33 am
Grant Fritchey (4/30/2010)
I agree with Brandie.I will add this though, if your index was truly covering, and the one used by the execution plan, you shouldn't get a key lookup. So it's either the wrong index, or it's not covering.
Well said Grant, That solved one of my issues too.
Maninder
www.dbanation.com
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply