public override long GetInt64(int i); 参数 i Int32 从零开始的列序号。 返回 Int64 指定列的值。 例外 InvalidCastException 指定的强制转换无效。 注解 不执行任何转换;因此,检索的数据必须已是 64 位有符号整数。 在调用此方法之前,调用 IsDBNull 检查 以获取 null 值。 适用于 产品版本 .NET Core ...
publicoverridelongGetInt64(inti); 參數 i Int32 以零為基底的資料行序數。 傳回 Int64 指定的資料行值。 例外狀況 InvalidCastException 指定的轉型無效。 備註 不會執行任何轉換;因此,擷取的數據必須是64位帶正負號的整數。 呼叫IsDBNull以在呼叫此方法之前檢查 Null 值。
GetSqlInt64 Method GetSqlMoney Method GetSqlSingle Method GetSqlString Method GetSqlValue Method GetSqlValues Method GetString Method GetValue Method GetValues Method IDisposable.Dispose Method IEnumerable.GetEnumerator Method IsDBNull Method NextResult Method ...
GetValues(Object[]) 使用目前資料列的資料行值填入物件陣列。 GetXmlReader(Int32) 擷取XML 型別的資料做為XmlReader。 IsCommandBehavior(CommandBehavior) 判斷指定的 CommandBehavior 是否與 SqlDataReader 的行為相符。 IsDBNull(Int32) 取得值,指出資料行是否含有不存在或遺漏的值。 IsDBNullAsync(Int32, Cancel...
SqlDataReader.GetInt64() Syntax Int64 GetInt64(Int32 i) Description The GetInt64() method returns the value of a specified column as type Int64. Example SqlConnection conn = new SqlConnection("Data Source=localhost; User Id=sa; Password=; Initial Catalog=northwind"); ...
GetInt32(index):用于获取指定列索引处的Int类型数据。 GetDouble(index):用于获取指定列索引处的Double类型数据。 GetBoolean(index):用于获取指定列索引处的布尔类型数据。 IsDBNull(index):用于检查指定列索引处的值是否为数据库中的空值。 SqlDataReader的优势在于它提供了高性能的数据读取方式,适用于大数据量的读...
SqlColumnBinder.GetInt64 方法 (DbDataReader) 项目 2013/05/20 本文内容 语法 .NET Framework 安全性 请参见 检索该列的值作为int给定读取器。 如果该列为空,则将引发异常 命名空间: Microsoft.TeamFoundation.Framework.Server 程序集: Microsoft.TeamFoundation.Framework.Server(在 Microsoft.TeamFoundation...
GetSqlGuid GetSqlInt16 GetSqlInt32 GetSqlInt64 GetSqlMoney GetSqlSingle GetSqlString GetSqlValue GetSqlValues GetSqlXml GetStream GetString GetTextReader GetTimeSpan GetValue GetValues GetXmlReader IsCommandBehavior IsDBNull IsDBNullAsync NextResult NextResultAsync Read ReadAsync SqlDependency SqlError ...
If DBNull.Value.Equals(Value) Then Return 0 Else Return Convert.ToInt32(Value) End If End Function Public Shared Function ToInt64(Value As Object) As Int64 If DBNull.Value.Equals(Value) Then Return 0 Else Return Convert.ToInt64(Value) ...
(覆盖 DbDataReader.GetBytes(Int32, Int64, array<Byte[], Int32, Int32)。) GetChar 在SQL Server Compact 的 .NET Compact Framework 数据提供程序中不受支持。 (覆盖 DbDataReader.GetChar(Int32)。) GetChars 从指定的列偏移量将字符流作为数组从给定的缓冲区偏移量开始读入缓冲区。 (覆盖 DbData...