Hi,
I am using the CVS trunk and I cannot get a ManyToOne relationship working. I get the
following error when deploying:
| org.hibernate.AnnotationException: mappedBy reference an unknown target entity
property: com.techsolcom.powermanager.Workout.workout in
com.techsolcom.powermanager.Athlete.workouts
|
My Code looks like this: Athlete.java
| @OneToMany(mappedBy="workout", cascade=CascadeType.REMOVE)
| private List<Workout> workouts = new ArrayList<Workout>();
|
| public List<Workout> getWorkouts()
| {
| return workouts;
| }
|
| public void setWorkouts(List<Workout> workouts)
| {
| this.workouts = workouts;
| }
|
|
..and Workout.java looks like this
| @ManyToOne
| @NotNull
| private Athlete athlete;
|
| public Workout(Athlete athlete)
| {
| this.athlete = athlete;
| }
|
| |
| | Any ideas ? I noticed in some of the examples, like the ContactList example that
there are entries in components.xml.. No idea if that's the problem. Thanks
| |
| |
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4072209#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...