I have a structure where the main table is USER, other tables include CATEGORY (contains user_id).
What I got after the standard reverse engineering procedure was:
- the class User contained a collection of categories,
- the class Category didn't contain the foreign key (user_id) but it did contain the User object.
Why did it not contain the foreign key as a class property?
And how do I join these two tables in HQL without that glue? HQL - please explain this part.