I have a shop with categories stored in database like below:
Categories are nested in each other using ParentCategoryId and root parent ID is 0.
I want to know how can I retrieve list of categories at most up to 3 levels not more than that?
Note: A thing that is important for me is that the number of maximum level can be adjustable if possible by a input parameter.
#c-sharp