MY SQL listing all the parent and childrens nodes with a JOIN in MY SQL 5.7

22 Views Asked by At

I am having a categories table like below [1]: https://i.stack.imgur.com/xbPCG.png

and another table called clients_categories [2]: https://i.stack.imgur.com/ertkx.png

clients_categories having only parent categories stored. I want to list parent categories and their all childrens (n Levels) In a Single query. Is it possible? Can somebody help? Expecting results : [3]: https://i.stack.imgur.com/KZ3B9.png

0

There are 0 best solutions below