The moose likes Object Relational Mapping and the fly likes Hibernate bidirectional manyToOne: How to get Index easily. Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Object Relational Mapping
Reply Bookmark "Hibernate bidirectional manyToOne: How to get Index easily." Watch "Hibernate bidirectional manyToOne: How to get Index easily." New topic
Author

Hibernate bidirectional manyToOne: How to get Index easily.

Manuel Petermann
Ranch Hand

Joined: Jul 19, 2011
Posts: 88

Hello again.
Lets say we got a customer with orders attached to it.


So is there an easier way than doing:


in an instance of Order. Because that seems to be a little too excessive.
All I want is the index in the array.

Thanks.


Please correct my english.
Vijitha Kumara
Bartender

Joined: Mar 24, 2008
Posts: 3563

If you frequently need this then it might better to have a method for just that?


SCJP 5 | SCWCD 5
[How to ask questions] [Twitter]
Manuel Petermann
Ranch Hand

Joined: Jul 19, 2011
Posts: 88

Of course, but I thought that it might be possible to map this value to an int in the right entity.
 
IntelliJ Java IDE
 
subject: Hibernate bidirectional manyToOne: How to get Index easily.
 
Threads others viewed
Java Persistence API
JPA CascadeType enquiry
JPA MappingException: Repeated column in mapping for entity
Hibernate 3 Annotations
JPA - need help with query
WebSphere development made easy
without the weight of IBM tools
http://www.myeclipseide.com

cast iron skillet 49er

more from paul wheaton's glorious empire of web junk: cast iron skillet diatomaceous earth rocket mass heater sepp holzer raised garden beds raising chickens lawn care CFL flea control missoula heat permaculture