Introduction

When you execute a query with the find() function, it returns a Promise that resolves to a ExtendedFieldsQueryResult object. This object contains the items that match the query, information about the query itself, and functions for paging through the query results.

Did this help?

items


itemsArray<ExtendedField>Read-only

Returns the items that match the query.

The current page of items retrieved by the query.

List of extended fields.

Note: When no items match the query, the items array is empty.

To paginate your query results, use the ExtendedFieldsQueryResult pagination properties and functions.

Perform a query and get the returned items from the result
JavaScript
Did this help?

length


lengthnumberRead-only

Returns the number of items in the current results page.

The page size is defined by the limit() function, can be retrieved using the pageSize property, and navigating through pages is done with the prev() and next() functions.

JavaScript
Did this help?

pageSize


pageSizenumberRead-only

Returns the query page size.

The page size is defined by the limit() function, can be retrieved using the pageSize property, and navigating through pages is done with the prev() and next() functions.

JavaScript
Did this help?

query


Returns the ExtendedFieldsQueryBuilder object used to get the current results.

Use the query property to create and run a new query by chaining additional ExtendedFieldsQueryBuilder functions to it. You can filter only on properties that have not not already been used in the previous query.

JavaScript
Did this help?

hasNext( )


Indicates if the query has more results.

Method Declaration
Copy
Request
This method does not take any parameters
Returns
Return Type:boolean
JavaScript
Did this help?

hasPrev( )


Indicates if the query has previous results.

Method Declaration
Copy
Request
This method does not take any parameters
Returns
Return Type:boolean
Get whether the query result object has previous results
JavaScript
Did this help?

next( )


Retrieves the next page of query results.

The next() function retrieves the next page of query results.

The page size is defined by the limit() function, can be retrieved using the pageSize property, and navigating through pages is done with the prev() and next() functions.

If items are added or removed between calls to next() the values returned by ExtendedFieldsQueryResult may change.

Method Declaration
Copy
Request
This method does not take any parameters
Returns
Return Type:Promise<ExtendedFieldsQueryResult>
JavaScript
Did this help?

prev( )


Retrieves the previous page of query results.

The prev() function retrieves the previous page of query results.

The page size is defined by the limit() function, can be retrieved using the pageSize property, and navigating through pages is done with the prev() and next() functions.

If items are added or removed between calls to prev() the values returned by ExtendedFieldsQueryResult may change.

Method Declaration
Copy
function prev(): Promise<ExtendedFieldsQueryResult>;
Request
This method does not take any parameters
Returns
Return Type:Promise<ExtendedFieldsQueryResult>
Get the previous page of a query result
JavaScript
const previousPage = oldResults .prev() .then((results) => { return results; }) .catch((error) => { console.error(error); });
Did this help?