About Entity

171-180 of 200Refresh
Forum
9

Merge with Parent/Child entities not possible

javax.persistence.Entity; import javax.persistence.EntityManager; import javax.persistence ... ; import org.junit.Before; import org.junit.Test; public class ObjectDbMergeTest { @Entity ... = id;   } } @Entity public static class ChildEntity {   @Id   @GeneratedValue   private
Forum
9

Populating entity id before transaction commit

transaction is committed so all returned entities are not populated with ID in this context. How can I force ODB to populate entity ID before transaction is committed? Or maybe there is another way to finding ID of entity before commit? You can use a SEQUENCE (or TABLE) value generation strategy
Forum
9

Removing an entity throws exception

to remove customer entity, when it's read by a query (it's attached), it throws this exception ... more   After this exception is the entity detached (why?). When I merge it, I can remove it without problems... The Customer class code: @Entity public class Customer implements Serializable { private
Issue
8

An entityManager.flush() with many entities is not possible

  The following exception occures if we call entityManager.flush() where the corresponding JPA PersistenceContext has many entities and relations. What is the reason for the exception? entityManager ... have not found a simple example to reproduce this exception. The entity model of the flushed JPA
Forum
8

Changing existing objects from Entity to Embedded

of another Entity. So as first try I changed only the metadata to this: entity classes) or embeddable
Forum
8

does ObjectDB / JPA support simple password field encryption of an entity class?

We are persisting certain passwords entered by user in a form binded with an entity. Is there any direct ObjectDB support to just encrypt the password field? We would like to either encrypt or make ... have one or two passwords field of an entity to protect. Appreciate any suggestions, Thanks. ObjectDB does not
Forum
8

Does run time enhancer due to GlassFish/Payara do anything that would affect loaded compile-time entity classes ?

do anything that would affect loaded compile-time enhanced entity classes (other than just logging, typically just info and warn level).     If the entity classes are already enhanced (build time enhancement
Forum
8

Exception after update of indices of Entity class

Hello, I changed the index definition of an entity class from @Index()... to @Indices() and now I get the following stacktrace upon start: Exception in thread "ODB-IndexActivation" java.lang ... = {"relations.related"}) }) public class Event extends Entity {     @Embedded     private Recurrence
Forum
8

Get multiple entities by Id

I'm trying to fetch a list of entities, by their Id. I Use this query: SELECT c FROM User c WHERE c.id IN :ids This querey works as long as I don't set the property "id" as @Id. If i set @Id to any ... ();         emf.close();     }     @Entity     public static class MyEntity {         private
Forum
8

Getting a list of all the entity class names

I was wondering if there is any way to get a list of the entity names in the database? You can use the Metamodel API as explained by the JPA Metamodel API page in the manual. Actually ... functionality (for example you can use it to get entity names or class names - which is not the same). dmoshal