ObjectDB Database Search

1-50 of 56 results

Detached JPA Entities

. The original serialized object is not affected. Cascading detach To automatically cascade a detach operation ... . ALL . When you detach an entity, the operation cascades to the entities referenced by that field, which can be a single entity or a collection of entities: @Entity class Employee { : @OneToOne ( cascade

Storing JPA Entities

calling the persist method or implicitly through a cascade operation. Explicit persist The following ... setting up automatic cascading persist operations. Cascading persist Marking a reference field ... operations are automatically cascaded to entities that are referenced by that field. A collection field

OneToMany and cascade delete problem

= Offer.class, mappedBy = "product", fetch = FetchType.LAZY, cascade = CascadeType.ALL) private Set offers ... , all "connected" offers are also removed ( cascade ). After that, when I iterate over offers in store ... and cascading delete from Product to Offer  are irrelevant to the exception. Let focus only in

Double persist of Entity field with Cascade.ALL

bookTitle; @OneToMany( cascade = CascadeType.ALL, fetch= FetchType.EAGER) private List chapters; The Chapter ... project demonstrates a bug in cascading merge to new entity objects. A new issue was filled . 

Cascading makeTransient

. I supposed that makeTransient() should work somehow cascading even for the fields of the Entity ... is probably new). Cascading makeTransient may solve the issue, but may cause other problems (slower

Cascading delete

Is there a configuration parameter to set this? dmoshal David Moshal You can set cascade delete using annotations (see also the Orphan Removal section). JDO defines similar annotations, and both JPA ... configuration. You cannot set global cascade delete since that will be too risky - you may delete the entire database. support Support

Puzzler: Not getting cascades on read from Spring context

I've determined that the database is correctly initialized, looking at it from the Object Explorer, I can run the code that loads the database in a Junit test and it's initializing the children objects correctly, but in the application running in Jetty with Spring, fetching is not cascading

JPA Entity Fields

EntityWithFieldSettings { @Basic ( optional =false) Integer field1; @OneToOne ( cascade = CascadeType ... an exception if you try to store an entity with a null value in that field. Cascade and fetch settings

jakarta.persistence.EntityManager

it. This operation cascades to every entity related by an association marked cascade =DETACH . If the given entity ... identity. This operation cascades to every entity related by an association marked cascade =MERGE ... , and has not been marked for removal, it is itself ignored, but the operation still cascades

jakarta.persistence.ManyToMany

using generics. Default: void/class Since: Jakarta Persistence (JPA) 1.0 CascadeType[] cascade (Optional) The operations that must be cascaded to the target of the association. When the target collection is a Map , the cascade element applies to the map value. Defaults to no operations

jakarta.persistence.ManyToOne

) 1.0 CascadeType[] cascade (Optional) The operations that must be cascaded to the target of the association. By default no operations are cascaded . Default: {} Since: Jakarta Persistence (JPA) 1.0

I can't get cascading delete to work in JDO

I enclose a Netbeans project which demonstrates the problem.  Cascading persist works, but cascading delete does not, leaving orphan objects. sjzlondon Steve Zara Thank you for this report. Apparently cascading delete has never been implemented in ObjectDB (see also "Deleting Dependent

Cascade.ALL with LAZY fetchtype does not clean up all references on remove

Hello, I have a tree of entity classes that reference others using Cascade .ALL in combination with FetchType.LAZY. If I now delete a root entity using EntityManager.remove all leaf nodes will not be deleted. This only applies to the leaf nodes. If I add an additional the behaviour changes

persisting object with long[][] arrays of array

;  @OneToMany(fetch = FetchType.EAGER, cascade = CascadeType.ALL) public long[] time;     @OneToMany(fetch = FetchType.EAGER, cascade = CascadeType.ALL) private long[][] a1;     @OneToMany(fetch = FetchType.EAGER, cascade = CascadeType.ALL) private long[][] a2;  

How to Remove records from many to many relationship tables in JPA

public class TransportationEvent { ... @ManyToMany(fetch = FetchType.EAGER, cascade = CascadeType ... { .... @ManyToMany( fetch = FetchType.LAZY, cascade = CascadeType.PERSIST) private List transportationEvents ... ", column 'conclusions_id' by searching some forums i got syntax like @ Cascade (org.hibernate

Optimistic locking: prevent version increment on entity collection attribute

", cascade =CascadeType.PERSIST)     private List readings = new ArrayList (); The cascade mode is required in order to persist the Reading instances with the Document   ... . support Support Ok, thank you for that. I have cascade persist set at the database configuration

jakarta.persistence.CascadeType.ALL

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.CascadeType ALL Cascade all operations Since: Jakarta Persistence (JPA) 1.0

jakarta.persistence.CascadeType.PERSIST

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.CascadeType PERSIST Cascade the persist operation Since: Jakarta Persistence (JPA) 1.0

jakarta.persistence.CascadeType.MERGE

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.CascadeType MERGE Cascade the merge operation Since: Jakarta Persistence (JPA) 1.0

jakarta.persistence.CascadeType.REMOVE

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.CascadeType REMOVE Cascade the remove operation Since: Jakarta Persistence (JPA) 1.0

jakarta.persistence.CascadeType.REFRESH

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.CascadeType REFRESH Cascade the refresh operation Since: Jakarta Persistence (JPA) 1.0

jakarta.persistence.CascadeType.DETACH

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.CascadeType DETACH Cascade the detach operation Since: Jakarta Persistence (JPA) 2.0

Multiple Collection Fields not update correctly

to another entity and they both reciprocally do: EntityB:     @OneToOne( cascade = CascadeType.ALL)     EntityA entityA;   EntityA:     @OneToOne( cascade = CascadeType.ALL)     EntityB entityB;   If I make only one of the cascade , then this bug

Storing objects problem

= interfaceMy;   } } } kiki Kristijan Your code persists only the root object. If you want to cascade ... adding an annotation to a reference:   @OneToMany( cascade =CascadeType.PERSIST)   private List children; You may also specify cascading persist globally as explained in the manual. support Support

Not releasing locked MST object

:176) at com.objectdb.o.TVS.e(TVS.java:170) at com.objectdb.o.TVS. cascade (TVS.java:157) at com ... .objectdb.o.TVS. cascade (TVS.java:157)     at com.objectdb.o.STA.C(STA.java:539)   

ManyToMany Set is null

@GeneratedValue     private long id;     @ManyToMany(fetch = FetchType. EAGER , cascade ... = FetchType. EAGER , cascade ={CascadeType. DETACH ,CascadeType. MERGE ,CascadeType. REFRESH }, mappedBy

Is it possible to remove parent/child entities without refresh?

;   @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "parent ... , cascade = { CascadeType.PERSIST, CascadeType.MERGE, CascadeType.REFRESH })   private ParentEntity

Merge with Parent/Child entities not possible

, cascade = CascadeType.ALL, mappedBy = "parent", orphanRemoval = true)   @MapKey(name = "childName ... long id;   @ManyToOne(fetch = FetchType.LAZY, cascade = { CascadeType.PERSIST, CascadeType.MERGE

_PersistenceException: Type is not found on getSingleResult.

= "estudiante", cascade = CascadeType.ALL, orphanRemoval = true)     private List

Problem on JPA Merge Entity.

Hello, I have a problem with the EntityManager.merge() function. I set a property value of an entity (statement) with an other entity (newSingleConstraint). newSingleValue is already persisted. I do this myself (no use of cascade because sometimes the newSingleValue is already in database

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: @Entity public class Foo { @Id @GeneratedValue private Long id; private String description; @OneToMany( cascade = CascadeType.ALL, fetch

Object belongs to another EntityManager - ERROR

(TVS.java:169) 10:29:15,110 ERROR [stderr] (http--10.23.3.98-8081-5) at com.objectdb.o.TVS. cascade

General Performance Issues Illustrated with a Specific Method

( cascade = CascadeType.ALL,fetch = FetchType.EAGER) private Person person; @Index private String phn

Query over the keySet of a map field with collection parameter

; } @OneToMany ( cascade = CascadeType.ALL) public Map map = new HashMap (); } @Entity public static class

Soft Reference Object Cache Recommendation

"ENT" that is a strong reference to that SoftReference.  Under "i", I see cascading ENT and ENT

TemporalType injection with Calendar using JPA

(TimePeriod id) { this.id = id; }   @OneToMany( cascade =javax.persistence.CascadeType.ALL,fetch=javax

Upgrade to 2.4.1_03

.java:160) at com.objectdb.o.TVS.j(TVS.java:169) at com.objectdb.o.TVS. cascade (TVS.java:156) at com

Does ObjectDB support lazy loading?

A { @Id @GeneratedValue Long id; @OneToMany(fetch=FetchType.LAZY, cascade =CascadeType.ALL) List list

OrphanRemoval not working?

Dear all, I have entities Invoice and InvoiceItem, their relation is defined: public class Invoice implements Serializable { ... @OneToMany(mappedBy="invoice", fetch=FetchType.EAGER,              orphanRemoval=true, cascade =CascadeType

NullPointer when accessing persistent field

(CLT.java:156) at com.objectdb.o.TVS.j(TVS.java:169) at com.objectdb.o.TVS. cascade (TVS.java:156) at com ... as follows; @OneToMany( cascade =CascadeType.ALL, mappedBy="z_component") @MapKey(name="z_schemeName ... .TVS.j(TVS.java:169) at com.objectdb.o.TVS. cascade (TVS.java:156) at com.objectdb.o.STA.Q(STA.java

NullPointerException when using multithreading

private String secondId; @OneToOne( cascade =CascadeType.ALL) private HashMap myMap; } @Embeddable public class EmbeddableA { @OneToOne( cascade =CascadeType.ALL) private HashMap myMap; } @Embeddable public class EmbeddableB { @OneToOne( cascade =CascadeType.ALL) private HashMap myMap; } I'm am trying

ClassCastException after upgrade to 2.3.5_03

, cascade =CascadeType.ALL, fetch=FetchType.EAGER) private Object payload; @OneToOne(orphanRemoval=true, cascade =CascadeType.ALL, fetch=FetchType.EAGER) private Map metadata; ... In this case the "payload

After using the enhancer, Lazy loaded collections are no longer loading. They are set as null

; } @Override public void setId(Long id) { this.id = id; } @OneToMany( cascade ={CascadeType.MERGE ... ; @OneToMany( cascade ={CascadeType.MERGE, CascadeType.PERSIST},        

ArrayIndexOutOfBoundException

without no reference to another entity. These entities are not persist in cascade , but explicitly by calling persist ... sure wheather this annotation is allowed when not cascade persist is used? The exception occurs

ArrayIndexOutOfBoundsException on flush

(orphanRemoval=true, cascade =CascadeType.ALL) private Map _nodes; The TaskNode contains a further Entity

Remove of an entry from a @OneToMany collection is not possible if the enhancer is disabled

{   @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, orphanRemoval = true)  

[ObjectDB 2.2.6_02] Unexpected exception (Error 990) at com.objectdb.o.OBC.aJ(OBC.java:961)

) at com.objectdb.o.TVS.j(TVS.java:169) at com.objectdb.o.TVS. cascade (TVS.java:156) at com.objectdb.o

ClassCastException thrown when running count query

Query. Then i realized that the cascade option in the entity class is ignored when doing DELETE. I

ObjectDB 2.4.5

global cascade persist in an ORM file. Fixed a NullPointerException during query execution ( issue

[ObjectDB 2.2.5_02] Unexpected exception (Error 990) com.objectdb.o.InternalException: java.lang.NullPointerException: null

; } @OneToMany( cascade =javax.persistence.CascadeType.ALL,fetch=javax.persistence.FetchType.EAGER