Statistics

  • Hi All!

     

    Why should we create statistics?

    How it will help and how we can identify that for these columns need to create statistics?

    When create clustered or non-clustered indexes statistics won’t create automatically?

     

     

    Thanks

    Shyam Koti

  • I've never fully decided if I'd actually want to explicitely create stats as against adding a secondary index - however.....

    Create stats for columns used in queries where an index doesn't exist to improve performance.

    Turn on auto create stats and SQL Server will do the job for you.

    You don't need stats explicitely created for columns with indexes - you still need to update them though ( sp_updatestats )

    Generally a graphical query plan will identfy missing stats /indexes.

    [font="Comic Sans MS"]The GrumpyOldDBA[/font]
    www.grumpyolddba.co.uk
    http://sqlblogcasts.com/blogs/grumpyolddba/

Viewing 2 posts - 1 through 2 (of 2 total)

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