Hello ...
I have a problem by mapping these two tables
i want the keys that are mapped not to be generated...
but to be entered manually ..
I am new to JPA and trying some examples ...
Can someone help ???
Create a row with isbn xx
and insert by that isbn 1-2-3 Instances with data by that isbn
the problem is i get the exception :
Exception in thread "main" org.hibernate.AnnotationException: mappedBy reference an unknown target entity property: jpa.beans.BookInfo.bookInfo in jpa.beans.Book.bookInfo
at org.hibernate.cfg.annotations.CollectionBinder.bindStarToManySecondPass(CollectionBinder.java:576)
So i use this example and get
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import jpa.beans.Book;
import jpa.beans.BookInfo;
import org.hibernate.SessionFactory;
import org.hibernate.cfg.AnnotationConfiguration;
import org.hibernate.classic.Session;
import org.hibernate.tool.hbm2ddl.SchemaExport;