What is the best way to insert data using Hibernate? As a example when I wont to insert new Order into order table. It has one-to-many relationship with Item. when we consider it on Object manner Order object has Item collection. Should I need to populate all variables(itemName,ItemId,ItemSize,, ) in Item object collection ?
If you can please give me the code sample on insert Order using hibernate session..
What is the best way to insert data using Hibernate? As a example when
Share
}
and item:
to query:
to insert could like this: