Click or drag to resize

SearchDefinitionBuilder<TDocument>.QueryString Method (FieldDefinition<TDocument>, String, SearchScoreDefinition<TDocument>)

Creates a search definition that queries a combination of indexed fields and values.

Namespace:  MongoDB.Driver.Search
Assembly:  MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.21.0+5a9c3311e158910b88195f290e6d4b1b2715d2b2
Syntax
public SearchDefinition<TDocument> QueryString(
	FieldDefinition<TDocument> defaultPath,
	string query,
	SearchScoreDefinition<TDocument> score = null
)

Parameters

defaultPath
Type: MongoDB.Driver.FieldDefinition<TDocument>
The indexed field to search by default.
query
Type: System.String
One or more indexed fields and values to search.
score (Optional)
Type: MongoDB.Driver.Search.SearchScoreDefinition<TDocument>
The score modifier.

Return Value

Type: SearchDefinition<TDocument>
A query string search definition.
See Also