All official database adapters support a common way for querying, sorting, limiting and selecting find and get method calls as part of params.query. Querying also applies update, patch and remove method calls.
Note
When used via REST URLs all query values are strings and may need to be converted to the correct type. In a v5 application this is done automatically using schemas.
Filters are special properties (starting with a $) added at the top level of a query. They can determine page settings, the properties to select and more.
$limit will return only the number of results you specify:
tip
With pagination enabled, to just get the number of available records set $limit to 0. This will only run a (fast) counting query against the database and return a page object with the total and an empty data array.
$skip will skip the specified number of results:
$sort will sort based on the object you provide. It can contain a list of properties by which to sort mapped to the order (1 ascending, -1 descending).
$select allows to pick which fields to include in the result. This will work for any service method.
Find all records that match any of the given criteria.
Find all records that match all of the given criteria.
Operators either query a property for a specific value or determine nested special properties (starting with a $) that allow querying the property for certain conditions. When multiple operators are set, all conditions have to apply for a property to match.
All fields that do not contain special query parameters are compared directly for equality.
Find all records where the property does ($in) or does not ($nin) match any of the given values.
Find all records where the value is less ($lt) or less and equal ($lte) to a given value.
Find all records where the value is more ($gt) or more and equal ($gte) to a given value.
Find all records that do not equal the given property value.
Searching is not part of the common querying syntax since it is very specific to the database you are using. For built in databases, see the SQL search and MongoDb search documentation. If you are using a community supported adapter their documentation may contain additional information on how to implement search functionality.
Last updated:
Released under the MIT License.
Copyright © 2012-2026 FeathersJS contributors
Released under the MIT License.
Copyright © 2012-2026 FeathersJS contributors