SqlDataRecord.GetSqlMetaData(Int32) SqlDataRecord.GetSqlMetaData(Int32) SqlDataRecord.GetSqlMetaData(Int32) SqlDataRecord.GetSqlMetaData(Int32) Method

定义

返回 SqlMetaData 对象,它描述由列序号指定的列的元数据。Returns a SqlMetaData object, describing the metadata of the column specified by the column ordinal.

public:
 virtual Microsoft::SqlServer::Server::SqlMetaData ^ GetSqlMetaData(int ordinal);
public virtual Microsoft.SqlServer.Server.SqlMetaData GetSqlMetaData (int ordinal);
abstract member GetSqlMetaData : int -> Microsoft.SqlServer.Server.SqlMetaData
override this.GetSqlMetaData : int -> Microsoft.SqlServer.Server.SqlMetaData
Public Overridable Function GetSqlMetaData (ordinal As Integer) As SqlMetaData

参数

ordinal
Int32 Int32 Int32 Int32

从零开始的列序号。The zero-based ordinal of the column.

返回

列元数据作为 SqlMetaData 对象。The column metadata as a SqlMetaData object.

异常

ordinal 小于 0 或大于列数(即 FieldCount)。The ordinal is less than 0 or greater than the number of columns (that is, FieldCount).

适用于