Home » Search

About remove

1-10 of 200Refresh
Manual
123

Deleting JPA Entity Objects

Existing entity objects can be deleted from the database either explicitly by invoking the remove method or implicitly as a result of a cascade operation. Explicit Remove In order to delete an object ... transaction, it can be deleted using the remove method: Employee employee = em.find(Employee.class, 1
Manual
72

Working with JPA Entity Objects

: New, Managed, Removed and Detached. When an entity object is initially created its state is New.  In ... the EntityManager’s remove method within an active transaction. The entity object changes its state from Managed to Removed, and is physically deleted from the database during commit. More details on object
Manual
70

CRUD Database Operations with JPA

a managed object (usually by retrieval) and invoke the remove method within the context of an active transaction: em.getTransaction().begin(); em.remove(p); // delete entity em.getTransaction ... object is marked for deletion by the remove method and is physically deleted from the database
JPA Doc
62

CascadeType.REMOVE

Enum Constant javax.persistence.CascadeType REMOVE Cascade remove operation Since: JPA 1.0
JPA Doc
62

remove(entity)

Method javax.persistence.EntityManager void remove(   Object entity ) Remove the entity instance. Parameters: entity - entity instance Throws: IllegalArgumentException - if the instance is not an entity or is a detached entity TransactionRequiredException - if invoked on a container-managed entity
Manual
51

CRUD Operations with JPA

Explains how to use JPA for CRUD database operations (persist, retrieve, update, remove).
Issue
31

Removing of an entity removes also another entity type

. All ResolverMapping entities are removed by a query (DELETE FROM ...), afterwards ResolverMapping entities ... with a result and after that a ToleranceDefinition entity is removed from database by entitymanager.remove(obj). Directly after remove we try to retrieve again the ResolverMapping entities from
Issue
30

Schema-Update: Deactivation of automatic entity class removing and introduction of a new class remove in the schema config

an exception in a use case in which we removed an entity. Exception in thread "main" java.lang ... objects of the 'removed' entity. And now we are a little bit confused, because we thought that the instances are removed if we remove the entity class. In the past we made a small check. We created
Manual
25

DELETE Queries in JPA/JPQL

the entity objects into an EntityManager. Removing these objects from the EntityManager within an active transaction, either explicitly by calling the remove method or implicitly by a cascading operation ... entity objects from the database. Removing entity objects from the database using a DELETE query
Forum
23

Remove an entity which attributes were changed - OptimisticLockException

and the entity is passed to plugin B. Plugin B changes an attribute on the entity. Plugin C removes ... exception of the removed entity. If this operations on the entity are executed in only one plugin ... will be removed, if we use three OSGi plugins. The difference between using one plugin or several plugins