共用方式為


AdomdConnection.GetSchemaDataSet 方法 (String, AdomdRestrictionCollection, Boolean)

Returns schema information from a data source by using a schema name to identify the information, applying any specified restrictions to the information, and optionally throwing an exception when inline errors occur.

命名空間:  Microsoft.AnalysisServices.AdomdClient
組件:  Microsoft.AnalysisServices.AdomdClient (在 Microsoft.AnalysisServices.AdomdClient.dll 中)

語法

'宣告
Public Function GetSchemaDataSet ( _
    schemaName As String, _
    restrictions As AdomdRestrictionCollection, _
    throwOnInlineErrors As Boolean _
) As DataSet
'用途
Dim instance As AdomdConnection 
Dim schemaName As String 
Dim restrictions As AdomdRestrictionCollection 
Dim throwOnInlineErrors As Boolean 
Dim returnValue As DataSet 

returnValue = instance.GetSchemaDataSet(schemaName, _
    restrictions, throwOnInlineErrors)
public DataSet GetSchemaDataSet(
    string schemaName,
    AdomdRestrictionCollection restrictions,
    bool throwOnInlineErrors
)
public:
DataSet^ GetSchemaDataSet(
    String^ schemaName, 
    AdomdRestrictionCollection^ restrictions, 
    bool throwOnInlineErrors
)
member GetSchemaDataSet : 
        schemaName:string * 
        restrictions:AdomdRestrictionCollection * 
        throwOnInlineErrors:bool -> DataSet
public function GetSchemaDataSet(
    schemaName : String, 
    restrictions : AdomdRestrictionCollection, 
    throwOnInlineErrors : boolean
) : DataSet

參數

  • schemaName
    型別:System.String
    The name of the schema to be retrieved.
  • throwOnInlineErrors
    型別:System.Boolean
    If true, inline errors cause an exception to be thrown; otherwise, DataRow.GetColumnError is used to determine the error generated.

傳回值

型別:System.Data.DataSet
A DataSet that represents the contents of the specified OLE DB schema table.

備註

If throwOnInlineErrors is true, this method behaves identically to GetSchemaDataSet. If throwOnInlineErrors is false, and there are errors that occur while retrieving schema information, the resulting DataSet may contain nullnull 參考 (在 Visual Basic 中為 Nothing) cells that would not normally be nullnull 參考 (在 Visual Basic 中為 Nothing). To determine the details of the errors that occur, you can use the DataRow.GetColumnsInError, DataRow.GetColumnError, DataRow.HasErrors, DataSet.HasErrors, and DataTable.HasErrors methods and properties.

請參閱

參考

AdomdConnection 類別

GetSchemaDataSet 多載

Microsoft.AnalysisServices.AdomdClient 命名空間