Wise man or Wise guy? You Decide

Just another WordPress.com weblog

Linked Server Test

Posted by sqlwiseguy on September 3, 2008

I recently found out that Microsoft had added a much needed component to linked servers in SQL Server 2005, sp_testlinkedserver. sp_testlinkedserver requires the @servername parameter and returns 0 if the linked server is available (success) and 1 if it is not (failure). I have seen several forum questions about how to check if a linked server is available and prior to 2005 you had to either check an error or a row count. This is a much needed improvement. Here’s a link to the documentation of it: sp_testlinkedserver BOL.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: