I have these entities
class Foo{ Set bars; } class Bar{ Foo parent; String localIdentifier; }
With this mapping (sorry,
If you are using oracle, you could also use deferrable constraints to postpone the checking of the constraints until the transaction is committed. Not sure if/how this is supported by other databases.