I don't really see the difference between:
{
"size": 128,
"query": {
"query_string" : {
"query" : "(Gravity) AND (AssetStatus:1 AND AvailableDate:[* TO 2013-11-29] AND ExpirationDate:[2013-11-29 TO ] AND MaturityRating:[ TO 25])"
}
},
"sort": "AvailableDate desc"
}
And
{
"size": 128,
"query": {
"query_string" : {
"query" : "(Gravity) AND (AssetStatus:1 AND AvailableDate:[* TO 2013-11-29] AND ExpirationDate:[2013-11-29 TO ] AND MaturityRating:[ TO 25])"
}
},
"sort": [
{ "AvailableDate" : "desc" }
]
}
May be I'm missing something.
--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet | @elasticsearchfr
Le 9 décembre 2013 at 21:39:48, Vladimir Khazin (vladimir.khazin@icssolutions.ca) a écrit:
Thank you for quick response!
This is somewhat static, I was hoping to provide ui with ability to specify dynamic sort order using Lucerne like syntax.
On Dec 9, 2013 3:34 PM, "David Pilato" david@pilato.fr wrote:
Are you looking for this? http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-request-sort.html
--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet | @elasticsearchfr
Le 9 décembre 2013 at 21:12:43, Vladimir Khazin (vladimir.khazin@icssolutions.ca) a écrit:
Is there a way to specify multi-field and/or descending sort order using lucene-like syntax e.g.:
{
"size": 128,
"query": {
"query_string" : {
"query" : "(Gravity) AND (AssetStatus:1 AND AvailableDate:[* TO 2013-11-29] AND ExpirationDate:[2013-11-29 TO ] AND MaturityRating:[ TO 25])"
}
},
"sort": "AvailableDate desc"
}
Or
{
"size": 128,
"query": {
"query_string" : {
"query" : "(Gravity) AND (AssetStatus:1 AND AvailableDate:[* TO 2013-11-29] AND ExpirationDate:[2013-11-29 TO ] AND MaturityRating:[ TO 25])"
}
},
"sort": "AvailableDate, AssetId"
}
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAMnv9kaKYLPmMvYBr_WXrb0viZDSc%2BHVOFfH8BBa3Kh768CT7A%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/etPan.52a62eac.1f16e9e8.2987%40MacBook-Air-de-David.local.
For more options, visit https://groups.google.com/groups/opt_out.