About eager

forum_thread

Composite indexes

Hi, I read your manual about defining Indexes for JPA Entities (http://www.objectdb.com/java/jpa/entity/index), but I still have some problems understanding how and when should I use them.   Let's start with some example then. Assume we have an entity that represents an interior design image, called Inspiration : ... ( fetch = FetchType . EAGER ) List<Integer> filterDescription ; // some integers ...

 
forum_thread

OEM licencing limitation

Hello, I have question regarding OEM licencing. We have an enhanced entity that contains list of unenhanced entities(by a mistake). We have already received the exception: Too many persistent objects (>1000000) - exceeds evaluation limit on that nonenhanced entity, but we have doubts how is the number of persistent objects counted. We unfortunately don't have the objectdb file anymore, but we have some doubts, that the number was not reached by the internal entitities.... OneToMany ( fetch = FetchType . EAGER , cascade = CascadeType . ALL ) private ...

 
forum_thread

LifeCycle Event with Embeddable classes

Hello, is there a way that lifecycle events like prepersist or preupdate are also fired for embeddable classes, not just for entities? My case looks as follows: ... . ALL , fetch = FetchType . EAGER ) private List<Bar> barList ;   @ ...

 
forum_thread

How do I achieve a Deep Fetch using JOIN FETCH?

I have an Entity type which is contains a collection of Embeddable objects, which in turn themselves contain a collection of Embeddable objects: @Embeddable class A { String val; }; @Embeddable class B { List<A> aList; }; @Entity class C { @Id long id; List<B> bList; };   Usually I'm content to have the B's and A's be lazily loaded, but I have a circumstance where I need to be able to work with the whole C object, with all its parts, as a detached object. ... object. I know that I can express one level of eager fetch in JPQL as follows: SELECT c FROM C JOIN FETCH ...

 
forum_thread

Double persist of Entity field with Cascade.ALL

I am building a JavaEE application using Netbeans 7.0.1, Glassfish 3.1 and ObjectDB 2.3.3. I have a Book class with entity field Chapter which has a CascadeType.ALL property. The Book fields are as follows: @Id @GeneratedValue(strategy = GenerationType.AUTO) private Long id; private String bookTitle; @OneToMany(cascade= CascadeType.ALL, fetch= FetchType.EAGER) private List<Chapter> chapters; The Chapter fields are as follows: ... . ALL , fetch = FetchType . EAGER ) private List<Chapter> chapters ; The ...

 
forum_thread

LEFT (OUTER) JOIN problem when mappedBy is defined

Hi all, I want to get objects with their lists, even when the lists are empty. So I've witten this query: "SELECT i FROM Invoice i LEFT OUTER JOIN i.itemList items" But this query never returns invoices without items! Only invoices with items. When I remove mappedBy from @OneToMany annotation, LEFT JOIN works correctly. Is this normal behaviour? Thank you Michael   Sample application ... = "invoice" , fetch = FetchType . EAGER , orphanRemoval = true , cascade = CascadeType . ...

 
issue

Lazy loading of mapped by (inverse) singular references

Feature Request Version: 2.0.0 Priority: Normal Status: Fixed Replies: 1 Type:  Feature Request ...

 
forum_thread

Does aggregate function "greatest" work on entity objects?

do not come to the function "compareTo" @Entity public class ChatHistoryItem extends AbstractObject implements Comparable {     private static final long serialVersionUID = 1L; ... class , fetch = FetchType . EAGER ) private List<ChatAttachment> attachments ; ...

 
forum_thread

Weird behaviour with enhanced classes and embedded entities

Hi, I've found some weird behaviour in my project (www.tinymediamanager.org): Sometimes some entries of my ArrayLists with embedded entities are missing. I've hunted the problem down to an enhanced/proxied list in my entity which contains embedded entities and some .add(obj) are simply failing. Here is a small sscce which reproduces the issue: ... . ALL , fetch = FetchType . EAGER ) private List<MyEmbeddedEntity> ...

 
forum_thread

ObjectDB 2.6.9_06 (embedded): Cascading merge resulting in duplicate objects

This issue maybe related to issue #110 (http://www.objectdb.com/database/issue/110). Because that issue has been closed as "fixed", I am reporting this new issue. This is my class definition: ... OneToMany ( fetch = FetchType . EAGER , cascade = CascadeType . ALL ) private ...