Which of these indexes should be deleted?

  • Huh? Don't understand what you're asking

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • I run this query on my database.

    Most of the result are : PK_ ... ?

    Why?

    (note that in all our tables , we insert an id column - identical - that is pk and clustered index. and Unrelated to business)

    What do I do now?

    change cluster? delete cluster?

  • sm_iransoftware (1/29/2015)


    I run this query on my database.

    Most of the result are : PK_ ... ?

    Why?

    (note that in all our tables , we insert an id column - identical - that is pk and clustered index. and Unrelated to business)

    What do I do now?

    change cluster? delete cluster?

    I presume that you aren't really talking about clusters, but clustered indexes. Deleting a cluster is quite a radical solution.

    Can you post a sample create table script for one of these?

    The absence of evidence is not evidence of absence
    - Martin Rees
    The absence of consumable DDL, sample data and desired results is, however, evidence of the absence of my response
    - Phil Parkin

  • sm_iransoftware (1/29/2015)


    I run this query on my database.

    Most of the result are : PK_ ... ?

    Those are probably the indexes enforcing the primary keys.

    What do I do now?

    change cluster? delete cluster?

    Why do you think you need to do anything?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Because I read somewhere , PK and Clustered index, can be separate (These two do not necessarily Be one thing)

    And it's better that clustered index related to Bussiness and on a benefit field that use in queries.

  • sm_iransoftware (1/30/2015)


    Because I read somewhere , PK and Clustered index, can be separate (These two do not necessarily Be one thing)

    And it's better that clustered index related to Bussiness and on a benefit field that use in queries.

    Which question are you answering here?

    The absence of evidence is not evidence of absence
    - Martin Rees
    The absence of consumable DDL, sample data and desired results is, however, evidence of the absence of my response
    - Phil Parkin

  • sm_iransoftware (1/30/2015)


    Because I read somewhere , PK and Clustered index, can be separate (These two do not necessarily Be one thing)

    They can be, yes.

    And it's better that clustered index related to Bussiness and on a benefit field that use in queries.

    Maybe, maybe not. Depends on queries, tables and a whole lot more. Changing a clustered index requires a huge amount of testing first. It's not something you do without analysis and testing first.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 7 posts - 16 through 21 (of 21 total)

You must be logged in to reply to this topic. Login to reply