0

I want to save an entity having one to many relationship in specific case where the nested entity throws unique constraint exception without rolling back the transaction.

I want to save the nested entity which is still unique and get an exception for duplicate entity.

Example: Entity A has list/set of entity B type containing X amount of duplicate records. While persisting in the database if the record exists already in database I want to know which record failed to persist from the list/set and the records to be successfully persisted.

Below are some reference for the same problem but no concrete solution.

- [https://stackoverflow.com/questions/32691128][1]
- [https://stackoverflow.com/questions/15731297][1]
- [https://stackoverflow.com/questions/3502279][1]
- [https://stackoverflow.com/questions/54343137][1]

0 Answers0