My data looks like this:
[
...
{
title: 'My first event',
guestlist: {
list: [
{
name: 'Christoffer'
}
]
}
}
...
]
And I'm trying to use this query:
body: {
query: {
bool: {
must: [
{
nested: {
path: 'guestlist',
query: {
bool: {
must: [
{
path: 'list',
query: {
bool: {
must: [
{
match_phrase_prefix: {
'list.name': 'christoffer'
}
}
]
}
}
}
]
}
}
}
}
]
}
}
}
But I just get the error that's in the title, what am I doing wrong?