Update statistics

  • Dear All,

    I run a stored procedure and it executes “infinite”. Stopped it and then I decided to update the statistics, because I’ve noticed for some tables they had never been updated.

    I run a simple ssis package only to update the statistics for the database and the run is "infinite". It was advancing up to 37% and then froze.

    Then I thought something is wrong with the database, and run DBCC CHECKDB and it runs “infinte” also.

    The database size is 202GB

    Available space is 2GB

    So I don’t know what to do next?

    Can anyone suggest something?

    Regards,

    IgorMi

    Igor Micev,My blog: www.igormicev.com

  • Is there an open transaction on which these processes are waiting?

    select @@trancount

    ______________________________________________________________________________________________
    Forum posting etiquette.[/url] Get your answers faster.

  • calvo (7/17/2012)


    Is there an open transaction on which these processes are waiting?

    select @@trancount

    @@trancount = 0

    Igor Micev,My blog: www.igormicev.com

  • Please do not double post, it's not good.

    All replies here

    ______________________________________________________________________________________________
    Forum posting etiquette.[/url] Get your answers faster.

  • @@trancount won't tell you anything other than if there's an open tran from that specifc session. It's of no use in this situation

    Check what the processes are waiting for (sys.dm_exec_requests, sys.dm_exec_sessions), post wait type and wait resource.

    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 5 posts - 1 through 4 (of 4 total)

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