I'm afraid not to understand.
Are you looking for something else that the example in ES site frontpage ?
$ curl -XPUT http://localhost:9200/twitter/tweet/2 -d '{
"user": "kimchy",
"post_date": "2009-11-15T14:12:12",
"message": "You know, for Search"
}'
$ curl -XGET http://localhost:9200/twitter/tweet/_search?q=user:kimchy
$ curl -XGET http://localhost:9200/twitter/tweet/_search -d '{
"query" : {
"term" : { "user": "kimchy" }
}
}'
$ curl -XGET http://localhost:9200/twitter/_search?pretty=true -d '{
"query" : {
"range" : {
"post_date" : {
"from" : "2009-11-15T13:00:00",
"to" : "2009-11-15T14:30:00"
}
}
}
}'
is it what you are after ?
Sorry if I misunderstood.
Le 14 juin 2012 à 07:35, Harsh harsh.chhatwani@gmail.com a écrit :
I didn't do anything, I don't know how to do it,
See, like in lucene first we create a QueryParser object and then with this object using the parse() method we create a query. Is there anything like this in elasticsearch?