I have an entity that follows this structure:
name: String(not null, unique),
value: Integer(not null)
id: Long(generated, not null, unique)
I have a list of entities(List<>), and I want to save them to a table or update if some were already in a table, but I need an effective way to do that with some bulk/batch insert/update. Now I've tried repository.saveAll and entityManager.merge, but I get the repeated value error, as it doesn't update the values that're already in a table. What should I do?