Search

      +
      The Search Service lets you create, manage, and query specially purposed indexes, defined on JSON documents within a Couchbase bucket.

      What is the Search Service?

      The Search Service provides extensive capabilities for natural-language querying: this allows special search-constraints to be applied to text-queries. Results can be scored, to indicate match-relevancy; and result-sets ordered correspondingly. Conjunctive and disjunctive searches can be performed, whereby common result-subsets from multiple queries can either be returned or omitted.

      A full overview of the Search Service is provided in The Search Service: Fundamentals. This includes information on the principal features of Couchbase Search Service, its architecture, and the latest feature-additions. Other information-sources include:

      • Performing Searches: An explanation of the steps required to prepare for and perform Search.

      • Searching from the UI: A brief introduction to the Search Service user interface provided by the Couchbase Web Console, with a step-by-step example of how to create a simple Search Index, and perform a search on it.

      • Searching with the REST API: Basic examples of how Search is performed with REST, and pointers to more complex examples.

      • Creating Indexes: A full description of the index-creation facility provided by the Couchbase Web Console, with explanations of each component to be used, and illustrations of how indexes can be designed to include specific subsets of documents and their fields.

      • Understanding Analyzers: An explanation of analyzers, which are used to process the text to be included in Search Indexes.

      • Queries: A detailed account of available query types, response objects, and result-sorting options.

      Performing Search from the SDK

      Couchbase SDKs provides an API for the support of Search querying. A detailed example of performing Search queries from the SDK is provided in Searching from the SDK.

      Note that to access Search, users require appropriate roles. The role fts_admin must therefore be assigned to those who intend to create indexes; and the role fts_searcher to those who intend to perform searches. For information on creating users and assigning roles, see the RBAC Roles page.

      Search from SQL++

      The search service can be accessed by search functions in SQL++ Query (formerly N1QL).