Search.../

query

Returns the ContactsQueryBuilder object used to get the current results.

Description

Use the query property to create and run a new query by chaining additional ContactsQueryBuilder functions to it.

Type:

Was this helpful?

Get the query that produced the current result

Copy Code
1let resultQuery = results.query;
Perform a query and get the query that produced the result

Copy Code
1import { contacts } from 'wix-crm-backend';
2
3// ...
4
5const originalQueryResults = await contacts.queryContacts()
6 .find();
7
8const newQueryResults = await originalQueryResults.query
9 .eq("info.addresses.country", "GB")
10 .find();
11
12const firstItem = newQueryResults.items[0];