how to get the Last 10 Run Status of a Stored Procedure

  • Hi All,

    Good Day...!

    We are using BODS for triggering a Stored procedure to execute a SQL Code.

    As BODS can not capture the SQL Execute Status, we can not capture the Status of the procedure run Status / Execution Status.

    Please need help provide some way on SQL Server to find the

    Last 10 Run Status of a Stored Procedure ???

    Output

    Procedure name, Date of Execution, Executed Session, Procedure Status (Success/Failed/Aborted...)

    Thanks in advance

  • Unless you have some custom logging implemented, you can't get that info. SQL doesn't track it.

    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
  • Hi,

    So you mean that we need to create Table / Process for logging in the Exeution Status of the Procedure.

    Is that correct ???

  • Yup, or set up an extended events session to run permanently. Dunno if the latter would meet your requirements though.

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

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