SQL Server Performance Tuning: Create indexes with included columns. I recently did some tuning work on a query that has computed columns in the SELECT. While the index that was being used by the query did contain columns used in the query’s WHERE clause performance was still not as fast as it could be. I checked the execution plan and could see that there were some parallelism operators, a non-clustered index scan with a key lookup on some computed columns that are part of the SELECT but not in the WHERE clause. After adding the computed columns as included columns to the index being used, the parallelism and key look up went away and the query really sped up.
CREATE NONCLUSTERED INDEX [ix_SQLRX_IncludeColIndex] ON [dbo].[Rebate]
More information from Microsoft here: https://msdn.microsoft.com/en-us/library/ms190806.aspx
Please log in again. The login page will open in a new window. After logging in you can close it and return to this page.