SqlDataRecord.IsDBNull(Int32) SqlDataRecord.IsDBNull(Int32) SqlDataRecord.IsDBNull(Int32) SqlDataRecord.IsDBNull(Int32) Method

定义

如果列序号参数所指定的列为 null,则返回 true。Returns true if the column specified by the column ordinal parameter is null.

public:
 virtual bool IsDBNull(int ordinal);
public virtual bool IsDBNull (int ordinal);
abstract member IsDBNull : int -> bool
override this.IsDBNull : int -> bool
Public Overridable Function IsDBNull (ordinal As Integer) As Boolean

参数

ordinal
Int32 Int32 Int32 Int32

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

返回

如果该列为 null,则为 true;否则为 falsetrue if the column is null; false otherwise.

实现

异常

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

适用于