ObjectDB Database Search

1-34 of 34 results

jakarta.persistence.ManyToMany

Jakarta Persistence (JPA) Annotation Type jakarta.persistence. ManyToMany Implemented Interfaces ... side, and the non-owning side must use the mappedBy element of the ManyToMany annotation to specify ... . The ManyToMany annotation may be used within an embeddable class contained within an entity class

Persist error @ManyToMany how to define correct entities relationships

; @ ManyToMany (cascade=CascadeType.PERSIST) private List categories = new ArrayList(); } @Entity public class ... .persistence.EntityManagerFactory; import javax.persistence.Id; import javax.persistence. ManyToMany ; import ... implements Serializable { @Id //@GeneratedValue private long id; @ ManyToMany (cascade=CascadeType.PERSIST

ManyToMany Set is null

@GeneratedValue     private long id;     @ ManyToMany (fetch = FetchType. EAGER , cascade ... {     @Id @GeneratedValue     private long id;     @ ManyToMany (fetch

Removing objects where ManyToMany relationships exist

Consider you have an entity Entity with the following unidirectional relationship: @ ManyToMany private Set setOfOtherEntities; public Set getOtherEntities() {     if (setOfOtherEntities == null) {       setOfOtherEntities = new TreeSet ();    

Retrieving JPA Entities

this behavior with an explicit FetchType.EAGER setting: @Entity class Employee { : @ ManyToMany ( fetch ... or @ ManyToMany annotation enables cascaded retrieval for the field. (ObjectDB currently does not

JPA Entity Fields

: @OneToOne , @ManyToOne : For references to entity types. @OneToMany , @ ManyToMany : For collections and maps

jakarta.persistence.MapKeyJoinColumn

; ... } Example 3: @Entity public class Student { @Id int studentId; ... @ ManyToMany // students and courses ... the collection table for the map value. If the join is for a map key for a ManyToMany entity ... column is in the collection table for the map value. If the join is for a map key for a ManyToMany

jakarta.persistence.MapKeyEnumerated

relationship of type Map , in conjunction with the ElementCollection , OneToMany , or ManyToMany annotation ... Employee { @ ManyToMany public Projects getProjects() { ... } @OneToMany @MapKeyEnumerated(STRING) public Map getEmployees() { ... } ... } See Also: ElementCollection OneToMany ManyToMany Since: Jakarta

jakarta.persistence.JoinColumn

entity. If the join is for a ManyToMany mapping or for a OneToOne or bidirectional ManyToOne ... . If the join is for a ManyToMany mapping or for a OneToOne or bidirectional ManyToOne / OneToMany

jakarta.persistence.MapKeyColumn

. If the map key is for a ManyToMany entity relationship or for a OneToMany entity relationship using a join ... is for a OneToMany or ManyToMany entity relationship using a join table, the name of the join table

jakarta.persistence.MapKeyClass

one of the collection-valued relationship annotations ( OneToMany or ManyToMany ). The MapKey annotation ... ; ... @OneToMany Map organization; } See Also: ElementCollection OneToMany ManyToMany Since: Jakarta

jakarta.persistence.AssociationOverride

address; // Unidirectional @ ManyToMany (targetEntity = PhoneNumber.class) List phoneNumbers; } @Entity public class PhoneNumber { @Id int number; @ ManyToMany (mappedBy = "contactInfo.phoneNumbers

jakarta.persistence.JoinTable

ManyToOne , OneToOne , ManyToMany , or OneToMany . See Also: JoinColumn JoinColumns Since: Jakarta

jakarta.persistence.MapKeyTemporal

with the ElementCollection , OneToMany , or ManyToMany annotation. Example: @OneToMany @MapKeyTemporal(DATE

jakarta.persistence.FetchType

ManyToMany OneToMany ManyToOne OneToOne Since: Jakarta Persistence (JPA) 1.0 Enum Constants EAGER Data

jakarta.persistence.CascadeType

OneToOne.cascade OneToMany.cascade ManyToMany .cascade Since: Jakarta Persistence (JPA) 1.0 Enum

jakarta.persistence.JoinColumn.name

. If the join is for a ManyToMany mapping or for a OneToOne or bidirectional ManyToOne / OneToMany

jakarta.persistence.MapKeyColumn.name

. If the map key is for a ManyToMany entity relationship or for a OneToMany entity relationship using a join

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 ... .annotations.CascadeType.DELETE_ORPHAN) and i applied that as @ ManyToMany (fetch = FetchType.EAGER, cascade

EntityManager.refresh takes a long time

.ALL) private List operations = new ArrayList (); @ ManyToMany (cascade = CascadeType.REFRESH) @NotNull private List selectedPersons = new ArrayList (); @ ManyToMany (mappedBy = "selectedPersons", cascade ... siteAuth; private DialogAction currentDialogAction; @ ManyToMany (fetch = FetchType.EAGER, cascade

Cascading persistence through an inverse field

Hi! I was playing with cascading persistence with @ ManyToMany and inverse @ ManyToMany ... transaction-related code to keep it simple. @Entity public class PointCollection { @ ManyToMany (cascade ... ) { points.add(p); } ... } @Entity public class Point { @ ManyToMany (mappedBy="points", cascade={PERSIST

joining of tables

: in Employee class: @ ManyToMany @JoinTable(name = "emp_add", joinColumns = @JoinColumn(name ... ", referencedColumnName = "add_id") ) public Set getAddress() { return address; } in Address class: @ ManyToMany

Are indexes implicitly created for relationships?

Do the following annotations @OneToMany @ManyToOne @ ManyToMany @OneToOne imply @Index   ? Thanks, Carl   FastModel Ben Schreiber Actually these annotations (except @ ManyToMany ) should apply @Unique on the @One side. But ObjectDB doesn't apply these indexes automatically

Query only works correctly when debug printing results

; @ ManyToMany private List topReqsList; @ ManyToMany private List bottomReqsList; private String name

Problem with merging / persisitng objects with @Embeddable field

public class ProductSet implements Serializable { @ ManyToMany (fetch = FetchType.EAGER, cascade ... Serializable, Convertable { @ ManyToMany (targetEntity = ProductSet.class, mappedBy = "productDemands

Is there a way to set EAGER fetch on all "ToMany" collection relationships

Given that the default seems to be FetchType.LAZY for all collections @OneToMany and @ ManyToMany . Such as a configuration option. Instead of having to explicitly set fetch in annotation code in every relationship. webel Dr Darren Kelly No. There is no such configuration option, since having EAGER

Speeding up reporting queries with size() on list

field in Inspiration entity. insp.products is a list with 0 to 600 objects. Definition: @ ManyToMany

Join query problem with new statetment

;(...)     @ ManyToMany (targetEntity = Product.class, fetch = FetchType.LAZY)   

How to delete M2M relationship?

In user model class I have the following: public class User implements Serializable {     @Id     @GeneratedValue(strategy = GenerationType.AUTO)     private Long id;     @ ManyToMany (mappedBy = "attendees", cascade

Relationship Annatations

hi,   what is the purpose of annotating a field with a RDB relationship shuch as OneToMany. ManyToMany etc? sprintf Reuben Alfred Using these annotations is optional in ObjectDB but required by standard JPA. You still need these annotations in ObjectDB to specify cascading / fetch policy and other settings. support Support

Fields in objects not populated in query result.

) private Folder parent; private boolean listable; @ ManyToMany (cascade=CascadeType.ALL) private Map

Example database world.odb

the relationships OneToMany and ManyToMany ? I want to see a working example :-) Robin_2005 Kompan Serge

Eager load Map

I'm having an issue eager loading a nested map. I've attached @ ManyToMany (fetch=FetchType.EAGER) attributes to no avail. If the map is viewed in the debugger or force iterated in the code it loads ok. The attached code attempts to replicate the scenario. Its not an exact match but is the best I

Explorer bug ? Objects seem to be missing from database in Class view, but are present as references

; webel Dr Darren Kelly This reply applies to both this issue and to support ticket: @ ManyToMany