<div class="meta" robots="noindex">

</div>

Class

# RecordSetQuery

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

## Description

Used to obtain as selection of records that a `Report</api/printing/reporting/report>` can use. This usage is no longer needed. You can pass a `RowSet</api/databases/rowset>` directly to a `Report</api/printing/reporting/report>`.

## Methods

<div class="rst-class">

table-centered_column_4

</div>

| Name                                       | Parameters                                    | Returns                            | Shared |
|--------------------------------------------|-----------------------------------------------|------------------------------------|--------|
| `Constructor<recordsetquery.constructor0>` | rs As `RowSet</api/databases/rowset>`         |                                    |        |
| `EOF<recordsetquery.eof>`                  |                                               | `Boolean</api/data_types/boolean>` |        |
| `Field<recordsetquery.field>`              | Idx As `Integer</api/data_types/integer>`     | `Variant</api/data_types/variant>` |        |
|                                            | Name As `String</api/data_types/string>`      | `Variant</api/data_types/variant>` |        |
| `NextRecord<recordsetquery.nextrecord>`    |                                               | `Boolean</api/data_types/boolean>` |        |
| `Run<recordsetquery.run>`                  |                                               |                                    |        |
| `Type<recordsetquery.type>`                | FieldName As `String</api/data_types/string>` | `Integer</api/data_types/integer>` |        |

## Method descriptions

<div id="recordsetquery.constructor0">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

RecordSetQuery.Constructor

**Constructor**(rs as `RowSet</api/databases/rowset>`)

<div class="note">

<div class="title">

Note

</div>

`Constructors</api/language/constructor>` are special methods called when you create an object with the `New</api/language/new>` keyword and pass in the parameters above.

</div>

Creates a new <span class="title-ref">RecordSetQuery</span> from the passed `RowSet</api/databases/rowset>`.

A `RowSet</api/databases/rowset>` can now be passed directly to the Run method of a Report. It is no longer necessary to first create a <span class="title-ref">RecordSetQuery</span>.

<div id="recordsetquery.eof">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

RecordSetQuery.EOF

**EOF** As `Boolean</api/data_types/boolean>`

`True</api/language/true>` when the record pointer is at the end of the set of records.

<div id="recordsetquery.field">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

RecordSetQuery.Field

**Field**(Idx As `Integer</api/data_types/integer>`) As `Variant</api/data_types/variant>`

Returns the value of the Field in the row the record pointer is pointing to.

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

<div class="rst-class">

forsearch

</div>

RecordSetQuery.Field

**Field**(Name As `String</api/data_types/string>`) As `Variant</api/data_types/variant>`

Returns the value of the Field in the row the record pointer is pointing to.

<div id="recordsetquery.nextrecord">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

RecordSetQuery.NextRecord

**NextRecord** As `Boolean</api/data_types/boolean>`

Moves the record pointer to the next record in the <span class="title-ref">RecordSetQuery</span>.

<div id="recordsetquery.run">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

RecordSetQuery.Run

**Run**

Does nothing and is included for compatibility.

<div id="recordsetquery.type">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

RecordSetQuery.Type

**Type**(FieldName As `String</api/data_types/string>`) As `Integer</api/data_types/integer>`

Returns the data type of the passed column.

Please refer to the table of field types in the `Database</api/databases/database>` class notes for the numeric values corresponding to SQL data types.

## Notes

Initially, the <span class="title-ref">RecordSetQuery</span> constructor was used to obtain a group of records from a `RowSet</api/databases/rowset>` to pass it to a `Report</api/printing/reporting/report>` in a suitable form. Please note that a `RowSet</api/databases/rowset>` can now be passed directly to the reporting engine.

## Compatibility

All project types on all supported operating systems.

## See also

`Object</api/data_types/additional_types/object>` parent class; `Report</api/printing/reporting/report>`, `ReportField</api/printing/reporting/reportfield>`, `ReportLabel</api/printing/reporting/reportlabel>`, `ReportLineShape</api/printing/reporting/reportlineshape>`, `ReportOvalShape</api/printing/reporting/reportovalshape>`, `ReportRectangleShape</api/printing/reporting/reportrectangleshape>`, `ReportRoundRectangleShape</api/printing/reporting/reportroundrectangleshape>`, `ReportPicture</api/printing/reporting/reportpicture>` classes, `Reports Module</api/printing/reporting/reports_module>` module.
