How to Poll SQL Server

  • How to poll SQL Server using T-SQL

  • When you say "poll" what exactly are you looking for? I can poll for connections, I can poll for service running (thru DMO best). What are you after?

  • quote:


    When you say "poll" what exactly are you looking for? I can poll for connections, I can poll for service running (thru DMO best). What are you after?


    I want to pool for the connection and if the connection fails i should get the response with in seconds

  • We poll by making an ADO connection. There have been examples where an issue would cause SQL Server to stop responding to connection requests though the service runs.

    If you want to do so through T-SQL, one of the easiest ways is using a linked server or remote data query (make sure you understand the security implications of both). If the query fails, it'll return a Sev 16 error, if I remember right. This is high enough to indicate a job failure on say SQL Server Agent.

    K. Brian Kelley

    http://www.truthsolutions.com/

    Author: Start to Finish Guide to SQL Server Performance Monitoring

    http://www.netimpress.com/

    K. Brian Kelley
    @kbriankelley

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

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