On my Production server (SQL2008) I have a query that returns suggestions of indexes.
SELECT * FROM sys.dm_db_missing_index_groups g
INNER JOIN sys.dm_db_missing_index_group_stats gs on gs.group_handle = g.index_group_handle
INNER JOIN sys.dm_db_missing_index_details d on g.index_handle = d.index_handle
Now, the most recent suggestions on it is this:
CREATE NONCLUSTERED INDEX IX_ACTIF_INC_NUMBER_ROUTE ON [dbname].[dbo].[CUSTOMER] ([ACTIF]) INCLUDE (NUMBER,ROUTE) WITH (ONLINE = ON)
CREATE NONCLUSTERED INDEX IX_ACTIF_ROUTE_INC_NUMBER ON [dbname].[dbo].[CUSTOMER] ([ACTIF], [ROUTE]) INCLUDE (NUMBER) WITH (ONLINE = ON)
Considering I don't know the queries in question, should I create the 2 Indexes, or only the second one as SQL would implicitly use it to cover the first one?
They both have similar numbers in USER_SEEKS (67k), USER_COST (0.95) and USER_IMPACT(64).
Any good and easy-to-understand documentation on how multi-column indexes should be optimized/implemented?
Thanks.