Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Find Duplicate Indexes Expand / Collapse
Author
Message
Posted Sunday, October 7, 2007 2:17 PM


Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Thursday, September 18, 2014 12:32 PM
Points: 349, Visits: 50
Comments posted to this topic are about the item Find Duplicate Indexes


"Keep Your Stick On the Ice" ..Red Green
Post #407798
Posted Thursday, June 19, 2008 9:52 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Saturday, February 19, 2011 7:19 PM
Points: 31, Visits: 101
Awesome query! Solved my headache today
Post #519983
Posted Wednesday, January 8, 2014 3:13 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Monday, July 14, 2014 6:20 AM
Points: 3, Visits: 46
Ouch! This doesn't take into account the sort order of the keys! It will identify these two indexes as duplicate:

CREATE NONCLUSTERED INDEX [idx01] ON [dbo].[table]
(
[d5comp] ASC,
[d5jbns] ASC
)

CREATE NONCLUSTERED INDEX [idx02] ON [dbo].[table]
(
[d5comp] ASC,
[d5jbns] DESC
)

Pretty sure that's not correct.
Post #1529123
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse