Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL-DMO doesn't return Server available
Message
From
20/01/2009 14:01:41
Peter Wagner
Point Informática Ltda.
Limeira, Brazil
 
General information
Forum:
Microsoft SQL Server
Category:
Other
Environment versions
SQL Server:
SQL Server 2000
Application:
Desktop
Miscellaneous
Thread ID:
01375255
Message ID:
01375579
Views:
30
Is there any way in SQL Server to check if a specific server is connected, if not than to connect, but in a automatic way?

TIA


>A linked server is an internal SQL Server object. It's not visible or accessible from outside of the SQL Server instance.
>
>>this is something what I'm looking for.
>>Just a question, will it show a linked server?
>>
>>I have to test if a specific SQL Server is connected, if it's not connected, connect using "EXEC sp_addlinkedserver....." .
>>
>>I made a test but the result is mixed, in some PC it only returns the local SQL Server (developer), in other it doesnt returns the SQL Server from the network, even if the server is mapped in the PC station.
>>Here it doesnt showed the linked server in no PC station, any ideia why?
>>I thing this is a stranger behavior why in some PC's it works an in others not..
>>
>>I made a test with SQL 2000 and it failed.
>>I the past the first code above always worked in SQL 2000, now it doesnt returns any walued even it theres a SQL Server in the PC station....
>>
>>LOCAL oSQLDMO AS SQLDMO.SQLserver
>>LOCAL oNames AS SQLDMO.NameList
>>oSQLDMO = CREATEOBJECT("SQLDMO.SQLserver")
>>oNames = oSQLDMO.APPLICATION.ListAvailableSQLServers()
>>FOR ix=1 TO oNames.COUNT
>> ? oNames.ITEM[ix]
>>ENDFOR
>>
>>
>>The same mixed results in SQL 2005 and 2008
>>
>>Thanks
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform