ObjectDB Database Search

1-50 of 200 results

JPA Entity Fields

The fields of persistable user-defined classes (entity classes, embeddable classes, and mapped superclasses) can be classified into the following five groups: Transient fields Persistent fields Inverse ( mappedBy ) fields Primary key (ID) fields Version field The first three groups (transient

jakarta.persistence.AccessType.FIELD

Jakarta Persistence (JPA) Enum Constant in jakarta.persistence.AccessType FIELD Field -based access is used. Since: Jakarta Persistence (JPA) 1.0

Index Definition

which fields to index carefully. Single- field index The following entity definition uses JDO's ... to fields . import javax.jdo.annotations.Index; import javax.jdo.annotations.Unique; @Entity public ... , which prevents duplicate values in the indexed field . If you try to commit or flush a transaction

DB Doctor sets type to "unknown" for new fields

Hi, we are using ObjectDB 2.5.4_04 on Linux. We added two new Boolean fields to a persistable type and run DB Doctor on the exiting DB file in order to update the schema. The fields are added ... DB file is what was produced by DB Doctor after adding the emergency and broadcast fields

Problem persisting a TreeSet field

Hello, I am getting a "java.lang.IllegalArgumentException: Can not set java.util.TreeSet field ...   lorenz2304 Benjamin Lorenz Your definition of field children is invalid in JPA - Only collection interface types ( Collection , Set , List , Map ) should be used in persistent field definition

JPA Attributes Annotations

Jakarta Persistence (JPA) annotations define how entity attributes ( fields and properties ... , relationship types, and data storage formats. General field mapping Configure standard state mapping behavior using the following annotations: Sets a field or property of a basic attribute (e.g., primitives

UPDATE query to set a new field after schema change

I've added a new property/ field to one of my objects and want to set the value of this (boolean ... the changes to the DB via file-save. But when I execute a select on the DB I see that the field is still "null" for all instances. How do I initialize the field ? KFlash Kevin You are right. Currently

Query over the keySet of a map field with collection parameter

It is possible to execute a query over a keySet of a map field with comparing to a collection ... EmbeddedSystems Using map values in queries is easier. Therefore, if the keys of the map field of EntityParent, i.e. public Map map = new HashMap (); are also available in the map value, e.g. the field

How do handle fields with java.net.URI class

fields like this: URI id; Set ids; These fields are very important for querying and we need an index ... than with unindexed String fields . Therefore, maintaining separate String fields , as you suggested, seems to be the current best solution. support Support

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 ... fields are as follows: @Id @GeneratedValue(strategy = GenerationType.AUTO) private Long id; private

Date field Index is corrupted due to time change

the bug, which affects indexes on pure Date fields (i.e. date with no time). ObjectDB converts pure ... move during commit different values can be obtained for the same field . Hopefully a new build that fixes ... fields will cause the corruption? An example would be beneficial. Also, can we assume that all version

Property fields

Hello   How can I use a Property, such as: javafx.beans.property.BooleanProperty as a field ... ; Thanks Russ russ0ne Russell Martin You can use a simple boolean or Boolean  persistent field in ... type property (i.e. the underlying persistent field of a  BooleanProperty could be java.lang.Boolean ). support Support

JPA inheritance issue with ObjectDB - Field not found in type error

; // other fields , getters, and setters } @Entity @Inheritance public class PharmaceuticalItem extends Item ... this query, I get the following error: Error executing query: Field 'retired' is not found in type 'com

Multiple Collection Fields not update correctly

  v2.8.8_2 I have an entity that has 2 collection fields : @OneToMany(fetch = FetchType.EAGER)      Collection position;      @OneToMany(fetch = FetchType.EAGER ... can only have 1 field that is a Collection .   position has values 8.0f, 8.0, 8.0 rotation has values 8.0f

java.sql.Time field off by 30 minutes

Hihi, I'm wondering if this is a bug. I have a simple entity with java.sql.Time field . On writing and readback, the field is found to be 30 minutes off. It is observed on objectdb explorer as well. Timestamp works perfectly fine. Ps. dont think its a UTC issue. My system is set at far off UTC

Why can't we persist an object with a field of type EnumMap in ObjectDB?

Hi, Is there a reason why we can't persist an object with a field of type EnumMap in ObjectDB? but it works fine for fields like = HashMap Thanks EKK EKK Emmanuel Keskes You can persist any Serializable type if you enable this ability in the configuration. But using this feature is not recommended

Indexing a field results in internal Exception

I have an application that I have been converting from JPA/MySQL to JDO/ObjectDB and I have hit a problem with indexing. An index on a String field is required to give good performance but if I add the @Index annotation to the field I eventually end up with an ObjectDB internal exception.  

Detached JPA Entities

navigation from detached objects is not supported. You can only access persistent fields ... to related entities, mark the reference field with CascadeType . DETACH or CascadeType . ALL . When you detach an entity, the operation cascades to the entities referenced by that field

JPA Persistable Types

fields . In addition, only entity class instances preserve their identity and are stored ... multiple persistent fields causes data duplication in the database. Entity classes An entity class ... . It can contain constructors, methods, fields , and nested types with any access modifier ( public , protected

Storing JPA Entities

fields is also stored. You can do this either by explicitly persisting every reachable object or by 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

Schema Update

The configuration element supports renaming packages, classes, and fields in ObjectDB databases ... is specified, a element serves as a container for child elements to rename classes and fields ... a container for child elements to rename fields in that class. The elements in the example rename the A , C

Collections in JPQL and Criteria Queries

is passed as an argument. As path expressions when navigating to a persistent collection field . IS [NOT ... OF operator checks whether a specified element is a member of a specified persistent collection field ... specifies that you should use the MEMBER OF operator to check a collection field and the IN operator

Database Management Settings

locking is fully automatic and enabled by default in ObjectDB, regardless of whether a version field is defined in the entity class. Some ORM JPA providers require a version field . You can disable

SELECT clause (JPQL / Criteria API)

projection. Projection extracts field values from entities to form the query results. The results ... only single-valued path expressions in the SELECT clause. Collection and map fields cannot be included

Strings in JPQL and Criteria Queries

String values can appear in JPQL queries in several forms: As string literals , for example, 'abc' and '' . As parameters when string values are passed as query arguments. As path expressions that navigate to persistent string fields . As the results of predefined JPQL string manipulation functions

Date and Time in JPQL and Criteria Queries

Date and time expressions can appear in JPQL queries in the following ways: As date and time literals --for example, {d '2011-12-31'} and {t '23:59:59'} . As parameters --when date and time values are passed as arguments. As path expressions --to navigate to persistent date and time fields . As

Logical Operators in JPQL and Criteria API

, a Boolean path (a field or property) is represented by Path : Path isInUN = country. get ("isInUN

JPA Metamodel Attributes

, wrappers, Strings), embedded objects, and associations (reference fields and properties

jakarta.persistence.Entity

. An entity class holds state, represented as persistent fields and properties: a field or property of basic type maps to a single column in one of the tables mapped by the entity, a field of property ... class must have at least one field or property annotated Id or EmbeddedId holding the primary key

jakarta.persistence.IdClass

: Annotation Target: Type Specifies a composite primary key type whose fields or properties map to the identifier fields or properties of the annotated entity class. The specified primary key type ... equality consistently with equality of the mapped primary key of the database table. The primary key fields

jakarta.persistence.Convert

: Annotation Target: Method, Field , Type Specifies how the values of a field or property are converted ... defined autoApply=true , or overriding the use of a converter specified by a field or property ... of each identifier used with the dot notation is the name of the respective embedded field or property

jakarta.persistence.MappedSuperclass

mapped to a database table. The persistent fields and properties of a mapped superclass are declared ... is FTEMPLOYEE table @Entity public class FTEmployee extends Employee { // Inherited empId field mapped to FTEMPLOYEE.EMPID // Inherited version field mapped to FTEMPLOYEE.VERSION // Inherited address field

jakarta.persistence.ManyToOne

: Annotation Target: Method, Field Specifies a single-valued association to another entity class ... the relationship field or property of the entity that is the owner of the relationship. A ManyToOne ... to specify the relationship field or property of the embeddable field or property on the owning

jakarta.persistence.Enumerated

: Annotation Target: Method, Field Specifies that a persistent property or field should be persisted as an enumerated type. This annotation is optional if the type of a persistent field or property ... the available options. The mapping may be explicitly specified by this annotation. If a persistent field or

jakarta.persistence.ManyToMany

: Annotation Target: Method, Field Specifies a many-valued association with many-to-many multiplicity ... the relationship field or property of the owning side. The join table for the relationship, if not defaulted ... the mappedBy element of the ManyToMany annotation to specify the relationship field or property

jakarta.persistence.Embeddable

of multiple persistent fields or properties, across several entities, and so distinct instances ... in the table or tables mapped by the owning entity. The persistent fields and properties ... its owning entity to another entity. However, an embeddable class may not have a field or property

jakarta.persistence.EmbeddedId

: Annotation Target: Method, Field Specifies that the annotated persistent field or property ... field or property must be an embeddable type, and must be explicitly annotated Embeddable . If a field or property of an entity class is annotated EmbeddedId , then no other field or property

jakarta.persistence.EnumType

how a persistent property or field whose type is a Java enum type should be persisted. See Also: Enumerated ... how to use EnumType . Enum Constants ORDINAL Persist enumerated type property or field as an integer. The ordinal value of an enum instance with no EnumeratedValue field is the value of its Enum.java.lang.Enum

com.objectdb.o._PersistenceException: Failed to locate set method for field property using reflection

._PersistenceException: Failed to locate set method for field property domain.PlatformTicker.platformConnector using ... can open the database and browse the data. It seems odd that the error message should complain about field ... the property based accessor for the field being complained about. Any ideas would be greatly

Enum fields are set to null and embeddable enum class does not show in explorer

I switched to version 2.8.2 and now it seems that my enum types are not recognized and the field ... ), however, when I open the database in the explorer the field "entities" holds one value which  ... the tree view it looks good in the list view it still shows null. However, if I click on null it opens and shows the fields of the type. itsme Martin Petzold

InternalException when querying indexed field using a list that contains duplicates

filter like this is used: ":ids.contains(originalId)" originalId is an indexed String field on the candidate class :ids is a list which contains a duplicate entry If the field is unindexed, or :ids does

jakarta.persistence.JoinColumn

: Annotation Target: Method, Field Specifies a column for joining an entity association or element ... is used): The concatenation of the following: the name of the referencing relationship property or field ... . If there is no such referencing relationship property or field in the entity, or if the join

jakarta.persistence.MapKey

: Annotation Target: Method, Field Specifies the map key for associations of type Map when the map key is itself the primary key or a persistent field or property of the entity that is the value of the map. If a persistent field or property other than the primary key is used as a map key

jakarta.persistence.EnumeratedValue

Interfaces: Annotation Target: Field Specifies that an annotated field of a Java enum type is the source of database column values for an enumerated mapping. The annotated field must be declared final ... . The annotated field must not be null, and must hold a distinct value for each value of the enum type

Step 2: Entity Class and Persistence Unit

static final long serialVersionUID = 1L; // Persistent Fields : @Id @GeneratedValue Long id; private

Step 4: Add a Controller Class

. A GuestDao component is automatically constructed and injected by Spring into the guestDao field

Step 2: Define a JPA Entity Class

should represent Point objects in the database. Apart from the @Entity annotation and the id field

Step 2: Define a JPA Entity Class

objects in the database. Besides the @Entity annotation and the id field (and its annotations

Getting Started with JPA and Eclipse

This is the Eclipse version of the Quick Start with JPA tutorial. It demonstrates how to create and run a simple JPA application in Eclipse. The demonstrated application uses JPA to store and retrieve simple Point entities, where each Point has two persistent fields : x and y

Step 7: Run the Spring Web App

; jetty:run in the Goals field and click Run . Open your browser at http://localhost:8080/Guestbook