I have two models: Ordine and DettaglioOrdine. I would like that, when I save an object of type “Ordine”, hibernate also save his child “DettaglioOrdine” (and this works). But, if I do a select query, the query is very very slow because hibernate retrieve also DettaglioOrdine. So, I would like the “Ordine” object without “DettaglioOrdine” object. “Ordine” model: DettaglioOrdine Model:
Tag: persistence
Problem with Foreign Key in @OneToOne annotation
I have spent a couple of days with a weird problem. There is a plethora of similar posts here in StackOverflow and I have check a lot of them but I was unable to find something similar with this. I have a Human Parent class A User child class : and also a CollectionOfContactMethods with composition relationship with the User.
Repository Pattern with Repository Factory
I’m trying to improve my Android persistence layer to be used across multiple applications. What i have done so far is to setup a base repository abstract class and also a base repository interface, the complete code can be check here: https://github.com/grmaciel/android-repository-ormlite Interface: Now all my repositories extends my base repository, like this: What i’m trying to achieve now is
Persisting set of Enums in a many-to-many unidirectional mapping
I’m using Hibernate 3.5.2-FINAL with annotations to specify my persistence mappings. I’m struggling with modelling a relationship between an Application and a set of Platforms. Each application is available for a set of platforms. From all the reading and searching I’ve done, I think I need to have the platform enum class be persisted as an Entity, and to have