tags:

views:

132

answers:

3

How can one determine which sql server instances are installed on the local machine and the network environment?

+1  A: 

You can use the EnumAvailableSqlServers method in the SMO (SQL Management Object) library. Check out Sample 1 or Sample 2

TLiebe
+1  A: 

sqlcmd and osql have the option -L which list the instances. Here and here are examples and tutorials how to use it.

Lukasz Lysik