Internal Website Search

101-150 of 200 results

Cross-platform license: Ubuntu and Windows 8

Cross-platform license: Ubuntu and Windows 8

Clarification on free license restrictions

Clarification on free license restrictions

2.7.3_03 Erroneous "Attempt to modify a primary key of a managed object"

a primary key of a managed object", but my application is not trying to change the primary key .  ... . Could you please provide details on the primary key of JdoBlob2 ? Is it composite? embedded ID ... in JDO to represent a combination of class + primary key and therefore it seems a bit strange to use

More Efficient Primary Keys

Can you give us a recommendation as we can represent the Key (UUID) most efficient? Both in terms ... . We already need the key before the entities are persisted so that we can build even references. a) Composite Primary Key   with two Longs b) Embedded Primary Key with two Longs c) Furthermore, as String

problem when primary key value is zero

and recommendations, in particular there are some primary keys with value == 0. These cause problems for objectDB, typically "JPA Unexpected argument as primary key ". When using eclipselink, there is a workaround ... Lister There is nothing wrong with 0 as a primary key value. For example the following code doesn't

Getting Foreign Key

How to get Foreign key using  org.eclipse.persistence.queries.WriteObjectQuery class ... can get line level primary key but i also nead to get foreign key which is belongs to header ... this i got pojo name query.getPrimaryKey() by using this i can get primary key now i nead

A bidirectional OneToOne association with a shared primary key

;bidirectional @OneToOne association that has a shared primary key , example: http://fruzenshtein.com/bidirectional-one-to-one-primary- key -association/ Can ObjectDB support this same specific relationship ... keys , i.e. the primary key will be stored at least on one side of the relationship

Unexpected query token 'KEY'

.customProperties cp WHERE KEY (cp) = :propertyName AND VALUE(cp) = :propertyValue ORDER BY td.createdTimeMillis I get the "Unexpected query token ' KEY '" error. Is there another way to do this and I am just using ... with a collection of embedded objects. This will also enable defining indexes on the keys /values

Index on map key

Is there a way to create an Index with @Index on the key of a map? wua Andreas Wurm Indexes on map keys as well as queries on map keys are currently not supported. But as a workaround you can use a collection of embedded objects, as demonstrated below: package test; import java.util.*; import

Failed to commit transaction: Attempt to reuse an existing primary key value (613)

.RollbackException Failed to commit transaction: Attempt to reuse an existing primary key value ... .EntityExistsException: com.objectdb.o.UserException: Attempt to reuse an existing primary key value ... with the same primary key . Unfortunately it is impossible to provide help based on this report

Foreign key constraint issue

Hi, I'm trying to create two tables (Parent and Child) with a foreign key constraint from Child ... one specific case that foreign key constraint doesn't apply and I can't figure how to make it work ... want to remove all orphaned child entities (as with a foreign key constraint). Interestingly

Intermittent: "Attempt to reuse an existing primary key value" when persisting a new instance

Hi,   I don't have a useful test case to expose this issue, but I am getting an intermittent "Attempt to reuse an existing primary key value". In this particular instance, the error is: Attempt to reuse an existing primary key value (com.x.y.z.UserPassword:1) (error 642) at com.objectdb.jpa

Error opening database with ObjectDB Explorer when using composite key

Hi, When I use a composite key in an entity and fill this database with this entity, ObjectDB explorer throws me an error when opening this database saying something about an invalid ID class ... has been attached to this ticket. The code itself looks like this:   KEY : public class PersonId

Merge failure with composite primary key

.3.7_21 should fix it. The composite primary key issue is unclear, since switching to a single primary key field doesn't seem to make any difference. support Support

ObjectDB JDO - foreign key constraints

Hi, I am new to both JDO and ObjectDB, and am struggeling to figure out how to define foreign key relationships. For instance, I have create two classes: @Entity public class Person implements ... ; Any help appreciated! ralfne Ralf Stefan Neumann ObjectDB doesn't enforce foreign key constraints

Changing Primary Key

that, and query the table all the PK fields are null or 0.  What can I do to modify primary keys ?     Trianglehead Json Error ObjectDB doesn't support changing primary keys , as it may break

Primary key generation problem after changing entity package

to reuse an existing primary key value... My primary keys are annotated as shown below : @Id

retrieve without key?

. i'm loading data from an external source. i use keys from that source. since i have a singleton i ... and can't see an option to retrieve an object w/o using a key . can this be done? duetto john cummings You can use a single result query . support Support

KEY() / VALUE() not recognized in JPQL??

Hi! Explorer says "unexpected token" on KEY (..: SELECT FROM individual.IndividualContact $1 LEFT OUTER JOIN $1.profile.title.name m WHERE ( KEY (m) = 'deu' AND VALUE(m) LIKE '%Dr%') profile = embedded entity title = referenced entity name = Map   thanks, Alex quasado Alexander Adam Yes

remove & persist in same transaction => Attempt to reuse an existing primary key value

to reuse an existing primary key value (Persist_Remove_Persist$EntityA:1)   We created a small ... key of the removed object. Obviously a possible workaround is to update the object instead

Can a Set be a foreign key?

I have two classes, Cell and Character.  Basically, the cell is like a room, and contains a variable (private Set cellHeldCharacters;) which holds the IDs of the characters within the cell (The IDs are Primary Keys ).  Can I use the Foreign Key annotation for the variable, or

Merge Issue: Attempt to reuse an existing primary key value

an existing primary key value (MyTestCase$MyEntityChild:'child1') at com.objectdb.o ... test case, i am pretty sure that "Attempt to reuse an existing primary key value" on my merge

selecting objects that have a particular key/value in persistant HashMap

that the pMap field of some Person objects has the key /value pair "location'/'California'.  Can I

Query on Embedded Primary Key?

Hi, I am trying to use Embedded Primary Key - but seems I can't retrieve them correctly with the query below - the query seem to work fine for other field (in the code = primkeycopy). The error I get when is below - it complains about a casting issue. Let me know how to fix

Uninitialized primary key (id = 0)

Exception in thread "main" [ObjectDB 2.2.9_04] javax.persistence.RollbackException Failed to commit transaction: Attempt to reuse an existing primary key value (image.Meta:0) (error 613) at com.objectdb.jpa.EMImpl.commit(EMImpl.java:277) I check the db by explorer.jar, and find the only one record

Internal ObjectDB error by read the primary key

Internal ObjectDB error by read the primary key

javax.persistence.MapKeyJoinColumn

a mapping to an entity that is a map key . The map key join column is in the collection table, join ... key constraint when table generation is in effect. If this element is not specified, the persistence provider's default foreign key strategy will apply. Since: JPA 2.1 boolean insertable default true

Eager Fetch of Map with Entities as Keys

Loading eagerly a map that uses entity objects as keys is currently unsupported, if the equals and hashCode methods of the keys are based on the key entity persistent content, since that content ... ;   MyKeyEntity key = new MyKeyEntity(" key ");         em

javax.persistence.JoinColumn

one-to-many association using a foreign key mapping // In Customer class @OneToMany @JoinColumn(name="CUST ... of a foreign key constraint when table generation is in effect. If this element is not specified, the persistence provider's default foreign key strategy will apply. Since: JPA 2.1 boolean insertable default

JPA Composite Key make Object Db throws "Unexpected exception (Error 990)"

Hello Object Db community :) I am using this wonderful library and I caught a strange exception while testing the "composite key " feature in JPA. Let's see what I am doing : @Entity public class ... be reproduced with a simple ( not embedded Id ) key with an enum type. Here is the code : package test

Page #9 entry 0 (key 'bjjl') has 75 extra bytes / Unexpected last index ID: -119 (expected -116)

------------------- [1] Page #9 entry 0 has unexpected object format [2] Page #9 entry 0 ( key 'bjjl') has 75 ... ] Page #3 entry 0 has unexpected object format [2] Page #3 entry 0 ( key 'guest') has 11 extra bytes

DISTINCT key causing internal exception on 2.6.4.b10

I observed that on new ObjectDb v.2.6.4.b10 query below causes internal exception SELECT DISTINCT $1 FROM Pa3DictionaryItem $2 JOIN $2.values $1 WHERE ($2.namespace == 'com.anritsu.pa3.ttcn3' AND $2. key == 'TliEvent' AND $1 != '') Query above also worked fine on ObjectDb version 2.6.1.b06 Harman

Object creation in the Explorer requires automatically set primary keys

The feature of creating new objects in the Explorer is currently supported only for entity classes that have primary keys that are set automatically. support Support

Merge throw exception "Attempt to reuse an existing primary key value"

Hi, if Id = 0 I got javax.persistence.EntityExistsException: com.objectdb.o.UserException: Attempt to reuse an existing primary key value (ru.dz.train.test.ZeroIdTest$MyEntity:0)   if Id=1 no exception code : import javax.persistence.*; public class ZeroIdTest {     public

javax.persistence.MapKeyColumn

the mapping for the key column of a map whose map key is a basic type. If the name element is not ... field or property; "_"; " KEY ". Example: @Entity public class Item { @Id int id; ... @ElementCollection ... "" (Optional) The name of the map key column. The table in which it is found depends upon the context

javax.persistence.EntityManager

to create and remove persistent entity instances, to find entities by their primary key ... ;Object primaryKey) Find by primary key . Search for an entity of the specified class and primary key . If the entity instance is contained in the persistence context, it is returned from

javax.persistence.PrimaryKeyJoinColumn

Specifies a primary key column that is used as a foreign key to join to another table. It is used ... to a primary table; and it may be used in a OneToOne mapping in which the primary key of the referencing entity is used as a foreign key to the referenced entity. If no PrimaryKeyJoinColumn annotation

javax.persistence.MapKey

key for associations of type java.util.Map when the map key is itself the primary key or a persistent ... other than the primary key is used as a map key then it is expected to have a uniqueness constraint ... . Example 1: @Entity public class Department { ... @OneToMany(mappedBy="department") @MapKey // map key

javax.persistence.ForeignKey

of foreign key constraints when schema generation is in effect. If this annotation is not specified, the persistence provider's default foreign key strategy will be used. The ConstraintMode value is used to specify whether foreign key constraints should be generated. The syntax used in

javax.persistence.Convert

to an embedded attribute or to a map collection attribute whose key or value is of embeddable type (in ... must be specified, and " key ." or "value." must be used to prefix the name of the attribute that is to be converted in order to specify it as part of the map key or map value. When the Convert

javax.persistence.MapsId

a ManyToOne or OneToOne relationship attribute that provides the mapping for an EmbeddedId primary key , an attribute within an EmbeddedId primary key , or a simple primary key of the parent entity. The value element specifies the attribute within a composite key to which the relationship attribute

javax.jdo.PersistenceManager

Since: JDO 1.0 T getObjectById (Class  cls, Object  key ) Looks up the instance of the given type with the given key . Parameters: cls - The type of object to load key - either the string representation of the object id, or an object representation of a single field identity key Return

javax.jdo.spi.PersistenceCapable

.ObjectIdFieldConsumer fm, Object oid) Copy fields to an outside consumer from the key fields in ... manager for each key field in the ObjectId. For example, an ObjectId class that has three key fields ... for the key fields. Parameters: oid - the ObjectId source of the copy. fm - the field manager that receives

javax.jdo.identity.LongIdentity

(Class pcClass, Long  key ) Constructor with class and key . Parameters: pcClass - the class key - the key Since: JDO 1.0 LongIdentity (Class pcClass, String str) Constructor with class and key . Parameters: pcClass - the class str - the key Since: JDO 1.0 LongIdentity (Class

javax.jdo.identity.IntIdentity

 pcClass, Integer  key ) Constructor with class and key . Parameters: pcClass - the class key - the key Since: JDO 1.0 IntIdentity (Class pcClass, String str) Constructor with class and key . Parameters: pcClass - the class str - the key Since: JDO 1.0 IntIdentity (Class

javax.jdo.identity.ByteIdentity

(Class pcClass, Byte  key ) Constructor with class and key . Parameters: pcClass - the target class key - the key Since: JDO 1.0 ByteIdentity (Class pcClass, String str) Constructor with class and key . Parameters: pcClass - the target class str - the key Since: JDO 1.0

javax.jdo.identity.CharIdentity

CharIdentity (Class pcClass, Character  key ) Constructor with class and key . Parameters: pcClass - the target class key - the key Since: JDO 1.0 CharIdentity (Class pcClass, String str) Constructor with class and key . The String must have exactly one character. Parameters: pcClass

javax.jdo.identity.ShortIdentity

ShortIdentity (Class pcClass, Short  key ) Constructor with class and key . Parameters: pcClass - the class key - the key Since: JDO 1.0 ShortIdentity (Class pcClass, String str) Constructor with class and key . Parameters: pcClass - the class str - the key Since: JDO 1.0

javax.jdo.spi.JDOImplHelper

 fm, Object oid) Copy fields to an outside source from the key fields in the ObjectId ... for each key field in the ObjectId. For example, an ObjectId class that has three key fields ( int id ... for implementing the ObjectIdFieldConsumer to store the values for the key fields. Parameters: pcClass

javax.jdo.annotations.ForeignKey

Implemented Interfaces: Annotation Annotation for a database foreign- key . Corresponds to the xml element "foreign- key ". Since: JDO 2.1 Public Annotation Attributes Column [] columns default {} Columns that compose this foreign key . Since: JDO 2.1 String deferred default "" Whether this foreign key