gudii9
asked on
hibernate one to one
Hi,
I was going through hibernate one-one example
http://www.mkyong.com/hibernate/hibernate-one-to-one-relationship-example-annotation/
In the main class why Stock is set to StockDetail object and also StockDetail set to Stock in both ways(is setting one way is not enough?)
stock.setStockDetail(stock Detail);
stockDetail.setStock(stock );
Please advice
I was going through hibernate one-one example
http://www.mkyong.com/hibernate/hibernate-one-to-one-relationship-example-annotation/
In the main class why Stock is set to StockDetail object and also StockDetail set to Stock in both ways(is setting one way is not enough?)
stock.setStockDetail(stock
stockDetail.setStock(stock
Please advice
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
This is how the Code entities are mapped to the Database fields, the DB Constraints and how the primary ID are generated.
ASKER
what is meaning of these annotations.
Please advice