Skip to content

Instantly share code, notes, and snippets.

@polyfractal polyfractal/gist:8409633
Last active Jan 3, 2016

Embed
What would you like to do?
curl -XPUT "http://localhost:9200/test" -d'
{
"mappings": {
"test" : {
"properties": {
"arrayfield" : {
"type": "string"
}
}
}
}
}'
curl -XPUT "http://localhost:9200/test/test/1" -d'
{
"arrayfield" : ["a", "b", "c"]
}'
curl -XGET "http://localhost:9200/test/test/1"
curl -XGET "http://localhost:9200/test/test/_search" -d'
{
"query": {
"match": {
"arrayfield": "b"
}
}
}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.