DB Shrink

  • Hi,

    Can anyone please tell me what are all the factors i have to check before shrinking a database.

  • 1. Check how much space are free. You can find this in database properties.

    a few other useful commands to learn to get the same information.

    DBCC showfilestats

    DBCC sqlperf('LOGSPACE')

    2. If this is production, do this at off-peak hours or scheduled down time.

  • Ummm.... I'd check the intelligence factor... domething made the DB grow... what makes you think it won't happen again...

    Shrinking DB's are one of the worst things you can do...

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Hi,

    I found an interesting articleb, you can determine whether you want to shrink or not.

    http://www.karaszi.com/SQLServer/info_dont_shrink.asp

    Regards,

    Ahmed

Viewing 4 posts - 1 through 3 (of 3 total)

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