Hi , I just read an article on Nonkey Columns in Nonclustered Indexes , which using the Include keywords when create index. If the table having Customer No , Customer Create Date , First Name , Last Name , and the query something is refer to Customer No OR Customer Create Date , and look for First Name and Last Name. In the above circumstances , should I create an key index that include Customer No and Customer Create Date and include (First Name and Last Name) ?Thanks ,Travis
Yes, I think it makes sense to have FirstName and LastName as INCLUDEd columns in the index. That way you have a covering index and there is no need to touch the base table.