About Elasticsearch Relationsship

Hi,
In Mysql i am maintaining below tables and i created same document types in ES also.

1.Order: storing orders data,
2. User_Order: Storing orderId and userId.
3.User: storing Users data.

Here i created Parent and child relation between Order(parent) and User_Order(Child), When i give orderId i able to get there child records but the problem was i am not able to get Users information/fields, how can i solve this problem.

Appreciate if anyone give solution.

And what about storing the user within the order document ?

Hi,
If I store user data in order again it's redundant, hence i stored user data in user type,In User_Order i'm storing both ID's Like user Id and Order Id,how to join there three types.

And? Why do you think it's a problem?

You can't do join in elasticsearch. Or you can do some kind of join using parent/child feature but I'd not do it unless I really need to use that.
Denormalizing data should be your first option.

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