Text Search文本搜索
On this page本页内容
MongoDB provides different text search capabilities depending on whether your data is hosted on MongoDB Atlas or a self-managed deployment.MongoDB提供了不同的文本搜索功能,这取决于您的数据是托管在MongoDB Atlas上还是托管在自管理部署上。
MongoDB Atlas SearchMongoDB Atlas搜索
To perform text search on data hosted on MongoDB Atlas, use MongoDB Atlas Search. Atlas Search supports fine-grained text indexing and a rich query language for fast, relevant search results.要对MongoDB Atlas上托管的数据执行文本搜索,请使用MongoDB Atlas Search。Atlas Search支持细粒度的文本索引和丰富的查询语言,以获得快速、相关的搜索结果。
To learn more and get started with Atlas Search, see:要了解更多信息并开始使用Atlas Search,请参阅:
Atlas Search Aggregation Pipeline StagesAtlas搜索聚合管道阶段Defining Atlas Search Indexes定义Atlas搜索索引Running Atlas Search Queries运行Atlas搜索查询
Atlas Search also offers common analyzers for parsing text for full-text search, including support for over 40 language-specific analyzers.Atlas Search还提供了用于解析全文搜索文本的通用分析器,包括对40多种特定语言分析器的支持。
Text Search on Self-Managed Deployments关于自我管理部署的文本搜索
For self-managed (non-Atlas) deployments, MongoDB's text search capability supports query operations that perform a text search of string content. 对于自我管理(非Atlas)部署,MongoDB的文本搜索功能支持执行字符串内容文本搜索的查询操作。To perform text search, MongoDB uses a text index and the 为了执行文本搜索,MongoDB使用文本索引和$text
operator.$text
运算符。
Views视图 do not support text search.不支持文本搜索。
To learn more about text search for self-managed deployments, see:要了解有关自我管理部署的文本搜索的更多信息,请参阅:
Perform a Text Search (Self-Managed Deployments)执行文本搜索(自我管理部署)Text Search Operators (Self-Managed Deployments)文本搜索运算符(自我管理部署)
MongoDB also supports text search for various languages. MongoDB还支持各种语言的文本搜索。For a list of supported languages, see Text Search Languages.有关支持的语言列表,请参阅文本搜索语言。