Run A Simple Search with the Capella UI
- Capella Operational
- how-to
Run a Search query from the Couchbase Capella UI to preview the search results from a Search index.
For more information about how the Search Service scores documents in search results, see Scoring for Search Queries.
Prerequisites
-
You have the Search Service enabled on a node in your operational cluster. For more information about how to change Services on your operational cluster, see Modify a Paid Cluster.
-
You have created a Search index.
For more information about how to create a Search index, see Create a Search Index.
-
You have logged in to the Couchbase Capella UI.
Procedure
To run a simple search with the Capella UI:
-
On the Operational Clusters page, select the operational cluster where you created your Search index.
-
Go to
. -
Next to your Search index or index alias, click Search.
-
In the Search field, enter a search query.
-
Press Enter.
-
(Optional) To view a document and its source collection, click a document name in the search results list.
Example
For example, the following query searches for the strings view
, food
, and beach
:
{
"explain": true,
"fields": [
"*"
],
"highlight": {},
"query": {
"query": "+view +food +beach"
},
"size": 10,
"from": 0
}
The query payload enables scoring explanations and term highlighting. It also returns all available fields in the index, and returns 10 results per page.
Use the collections parameter in your request to specify an array of collections to search from the Search index.
|
Next Steps
If you do not get the search results you were expecting, you can change the JSON payload for your Search query.
You can also Search Index Features.