USING Listview=

Optional clause used to search within a single given object’s list view. Only one list view can be specified. Only the first 2,000 records of the list view are searched, according to the sort order the user has set for the list view. The clause can be used in API version 41 or later.

Example

The following SOSL statement searches through the MVP Customers list view for the Account object for Acme.
FIND {Acme} IN ALL FIELDS RETURNING Account(Id, Name USING ListView=MVPCustomers)

Example

The following SOSL statement searches through the recently viewed list view for the Account object for Acme.
FIND {Acme} IN ALL FIELDS RETURNING Account(Name USING LISTVIEW = Recent ORDER BY Name ASC NULLS FIRST, Id ASC NULLS FIRST LIMIT 51)

Supported APIs

The clause in SOSL is supported in SOAP API, REST API, and Apex.