How get the parent name of a _doc

Hi,
My document is as follow :

ss

I search in this document by name.
Now i want get parent name of result.
For example :
When I search "Red" , i want get this result :
Red in Colors (parent_id of Red is 3 & name of 3 id is Colors)
Or
When I search "BMW" , i want get this result :
BMW in Cars (parent_id of BMW is 1 & name of 1 id is Cars)
Tnx!

That sounds like a join between different documents, which is not supported by Elasticsearch. I would recommend structuring your data in a different way.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.