From: tomo on
I have a an entity parent A, and it has a Set od entity-s B. Entity B
has custom hibernate annotation
all-delete-orphan. Let's say that I have one parent A in DB, and 10 B in
db. When I delete one
entity in set, and write entityManager.merge(A) it deletes that child
record in db,and that's great, but
the problem is that I have a sitauation where I have one parent(A) in
db, which has 20000 child records,
and where i delete one of 20000 records and write entityManager.merge(A)
it run's out of memory.
Any suggestions how to solve that ?

Thanks in advance.