Click or drag to resize

SphinxSearchOptionsGroupBy Property

Gets or sets the attribute to group by.

Namespace:  SphinxConnector.NativeApi
Assembly:  SphinxConnector (in SphinxConnector.dll) Version: 5.3.0
Syntax
public string GroupBy { get; set; }

Property Value

Type: String
The attribute to group by.
Examples
SphinxClient sphinxClient = new SphinxClient();
sphinxClient.SearchOptions.GroupBy = "last_update";
sphinxClient.SearchOptions.GroupByFunction = SphinxGroupByFunction.Day;

SphinxSearchResult searchResult = sphinxClient.Query("room", "sakila");

foreach (SphinxMatch match in searchResult.Matches)
{
    Console.WriteLine("DocumentId {0} Weight {1}", match.DocumentId, match.Weight);
}
See Also