Join reference data

Is it possible to join reference data from 2 separate index’s and join / visualize them? For example:

Index: company
_id: 1
“companyName” : “Nike”
“companyAddress” : “Some Address”

index: Products
_id: 54332
“Name”:“Sneaker A”
“CompanyId” : 1

When I get document ID 54332 from Products, it will have combined from ComanyID 1:

“Name”:“Sneaker A”
“companyName” : “Nike”
“companyAddress” : “Some Address”

@brolly759 Hello. Did you solve the usecase you mentioned in your query?
I too need help on this

@brolly759 @anushaboggarapu Found any solution. I too am desperately looking for the same. SO far, there’s the Metaqueries plugin, but that’s for Arithmetic and Time shift operations only.

That’s not the way elasticsearch works…
You need to re-thinking the ingestion strategy.
As per my understanding, if you get the data from jdbc, you need to ensure that the data is de-normalized.
It’s mean, no relationship in the elasticsearch document.
You can build the view or the query like below to ingest to elasticsearch

select, a.companayName, a.companyAddress from company a, product b where a.company_id=b.product_id

If you want to join/relatationship in elasticsearch like RDBMS, please find another solution.

Fadjar Tandabawana