Register / Login
Win a copy of
Java 9 Revealed
this week in the
Features new in Java 9
this forum made possible by our volunteer staff, including ...
Roel De Nijs
Stephan van Hulst
Object Relational Mapping
keep getting error: More than one row with the given identifier was found: 000001, for class
posted 7 years ago
message: More than one row with the given identifier was found: 000001, for class com.highmark.fm.model.TeamModel
the thing is I want multiple rows with the same primary key returned.....
@NamedQuery(name = "getTeamRoster", query = "select teammdl from TeamModel teammdl where teammdl.teamID = :teamID")
also tried this (saw in another forum somewhere) to no avail...
@NamedQuery(name = "getTeamRoster", query = "select new list (teammdl) from TeamModel teammdl where teammdl.teamID = :teamID")
I also tried using the @ManyToOne above the code, to no avail....here is my sql...(I am returning into a List in my code)...any help is really appreciated
Boost this thread!
EJBQL and its return type
Unable to use @NamedQuery in a session bean?
Select an entity object in a NamedQuery
OneToOne Relation Exception