InstAPI.GetSQLServerByName Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Sorts the list of SQL servers by name using a Boolean expression.
Overloads
GetSQLServerByName(String, String) |
Sorts the list of SQL servers by name using a Boolean expression. |
GetSQLServerByName(String, String, StringBuilder, UInt32) |
Obsolete.
Sorts the list of SQL servers by name using a Boolean expression. |
GetSQLServerByName(String, String)
Sorts the list of SQL servers by name using a Boolean expression.
public:
static System::String ^ GetSQLServerByName(System::String ^ hostName, System::String ^ instanceName);
public static string GetSQLServerByName (string hostName, string instanceName);
static member GetSQLServerByName : string * string -> string
Public Shared Function GetSQLServerByName (hostName As String, instanceName As String) As String
Parameters
- hostName
- String
A string that represents the Host.
Returns
The list of SQL servers by name using a Boolean expression.
Applies to
GetSQLServerByName(String, String, StringBuilder, UInt32)
Caution
This overload is obsolete; use GetSQLServerByName(hostName, instanceName), instead.
Sorts the list of SQL servers by name using a Boolean expression.
public:
static bool GetSQLServerByName(System::String ^ hostName, System::String ^ instanceName, System::Text::StringBuilder ^ sqlServer, System::UInt32 % bufferSize);
[System.Obsolete("This overload is obsolete; use GetSQLServerByName(hostName, instanceName), instead.")]
public static bool GetSQLServerByName (string hostName, string instanceName, System.Text.StringBuilder sqlServer, ref uint bufferSize);
[<System.Obsolete("This overload is obsolete; use GetSQLServerByName(hostName, instanceName), instead.")>]
static member GetSQLServerByName : string * string * System.Text.StringBuilder * uint32 -> bool
Public Shared Function GetSQLServerByName (hostName As String, instanceName As String, sqlServer As StringBuilder, ByRef bufferSize As UInteger) As Boolean
Parameters
- hostName
- String
A string that represents the Host.
- sqlServer
- StringBuilder
A string input that is used for SQL Server.
- bufferSize
- UInt32
A pointer to a DWORD value to supply the length of the buffer. Returns the required length if the supplied buffer is too small.
Returns
true
if the SQL Server names are sorted by name; otherwise, false
.
- Attributes