How to get statistics after executing Procedure

  • After executing a procedure I have to know the statistics like Reads, Writes, Duration, RowCounts.

    Can any one tell me how to achieve this?

    This could be done by Sql profiler but I need these by query.

  • Set Statistics IO ON

    exec your Sp

    Set Statistics IO OFF

    -------Bhuvnesh----------
    I work only to learn Sql Server...though my company pays me for getting their stuff done;-)

  • Another useful statistics statement is «Time», it will show you the number of milliseconds for parsing, compiling and executing your statements:

    Set Statistics TIME ON

    exec your Sp

    Set Statistics TIME OFF

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

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