Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (中文) » SQL Anywhere 服务器 - 编程 » SQL Anywhere 数据访问 API » SQL Anywhere .NET 2.0 API 参考 » iAnywhere.Data.SQLAnywhere 命名空间 (.NET 2.0) » SADataReader 类

 

GetValues 方法

获取当前行中的所有列。

语法
Visual Basic

Public Overrides Function GetValues( _
   ByVal values As Object() _
) As Integer
C#

public override int GetValues(
   object[] values
);
参数
  • values   保存结果集中整个行的对象数组。

返回值

数组中的对象数。

注释

对大多数应用程序而言,GetValues 方法提供了一种有效率的检索所有列而不是分别检索每个列的方法。

您可以传递一个包含的列数比生成的行中包含的列数少的 Object 数组。只有 Object 数组保存的数据才会复制到数组中。您还可以传递长度比生成的行中包含的列数大的 Object 数组。

对于值为 NULL 的数据库列,此方法返回 DBNull。

另请参见