Skip to content

Instantly share code, notes, and snippets.

View andreasch's full-sized avatar

Andreas Christoforides andreasch

View GitHub Profile
@andreasch
andreasch / has-child-on-contact.sh
Created September 25, 2012 17:13
Querying a parent type that is also a child type for another type
#!/bin/bash
echo "Performing a has_child search on contacts"
curl -XGET 'http://localhost:9200/contact/_search?pretty=true' -d '
{
"query" : {
"filtered" : {
"query" : {
"match_all" : { }
},
"filter" : {