SqlSyncDescriptionBuilder.GetDescriptionForTable Method (String, Collection<String>, SqlConnection)
Returns a DbSyncTableDescription object that contains schema information about the specified table in a SQL Server database.
Namespace: Microsoft.Synchronization.Data.SqlServer
Assembly: Microsoft.Synchronization.Data.SqlServer (in Microsoft.Synchronization.Data.SqlServer.dll)
Syntax
'Declaration
Public Shared Function GetDescriptionForTable ( _
tableName As String, _
columnNames As Collection(Of String), _
connection As SqlConnection _
) As DbSyncTableDescription
'Usage
Dim tableName As String
Dim columnNames As Collection(Of String)
Dim connection As SqlConnection
Dim returnValue As DbSyncTableDescription
returnValue = SqlSyncDescriptionBuilder.GetDescriptionForTable(tableName, _
columnNames, connection)
public static DbSyncTableDescription GetDescriptionForTable(
string tableName,
Collection<string> columnNames,
SqlConnection connection
)
public:
static DbSyncTableDescription^ GetDescriptionForTable(
String^ tableName,
Collection<String^>^ columnNames,
SqlConnection^ connection
)
static member GetDescriptionForTable :
tableName:string *
columnNames:Collection<string> *
connection:SqlConnection -> DbSyncTableDescription
public static function GetDescriptionForTable(
tableName : String,
columnNames : Collection<String>,
connection : SqlConnection
) : DbSyncTableDescription
Parameters
- tableName
Type: System.String
The name of the table for which to retrieve a description.
- columnNames
Type: System.Collections.ObjectModel.Collection<String>
A list of columns for which to retrieve information.
- connection
Type: System.Data.SqlClient.SqlConnection
A SqlCeConnection object that contains a connection to the database.
Return Value
Type: Microsoft.Synchronization.Data.DbSyncTableDescription
A DbSyncTableDescription object that contains schema information about the specified table.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | connection is null reference (Nothing in Visual Basic). |
ArgumentException | tableName is a null reference (Nothing in Visual Basic) or empty. |
See Also
Reference
SqlSyncDescriptionBuilder Class