Created
January 20, 2013 15:43
-
-
Save gerektoolhy/4579407 to your computer and use it in GitHub Desktop.
elastic search query
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
dark@ubuntu:~$ curl -XGET 'http://localhost:9200/twitter/tweet/2?pretty=true' | |
{ | |
"_index" : "twitter", | |
"_type" : "tweet", | |
"_id" : "2", | |
"_version" : 1, | |
"exists" : true, "_source" : | |
{ | |
"user": "kimchy", | |
"postDate": "2009-11-15T14:12:12", | |
"message": "Another tweet, will it be indexed?" | |
} | |
dark@ubuntu:~$ curl -XGET 'http://localhost:9200/twitter/tweet/_search?q=user:kimchy&pretty=true' | |
{ | |
"took" : 3, | |
"timed_out" : false, | |
"_shards" : { | |
"total" : 5, | |
"successful" : 5, | |
"failed" : 0 | |
}, | |
"hits" : { | |
"total" : 0, | |
"max_score" : null, | |
"hits" : [ ] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment