Created
February 27, 2018 15:00
-
-
Save AntonyBaasan/69dd01aecc928689b20b40728f3fda4c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var response = _client.Search<ElasticFileInfo>(s => s | |
.Index(_indexName) | |
.From(0) | |
.Size(10000) | |
.Query(qry => qry.QueryString(q => q.Query(queryString))) | |
.StoredFields(f => f.Fields(p => p.CreatedBy)) | |
.Aggregations(a => a | |
.Terms("types", st => st | |
.Field(f => f.Type)) | |
.Terms("addedby", st => st | |
.Field(f => f.CreatedBy.Suffix("keyword"))) | |
) | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment