Amazon So we've created a database table to embody the concept of a Keyword, a table to join a Keyword to itself, the actual Java class that embodies the Keyword, the corresponding Hibernate configuration. Now you should be able to test our code.
Suppose manager is an instance of a class whose job is to do CRUD (create, read, update, delete) operations on a Hibernate aware entity. Suppose we already have Keywords with keyword_id 243, 250, 260. Here's how we add a couple of keywords to another keyword as its children:
With any luck you'll run the code without an error and see that the corresponding rows created in the database correctly. Congratulations! Questions? Let me know! Otherwise enjoying Java and Hibernate!