borinquenkid commented on issue #16691:
URL: https://github.com/apache/grails-core/issues/16691#issuecomment-6385630386

   Closing #16745 as a duplicate of this one; what it adds:
   
   - An in-repo reproduction on H2: `SharedJoinTableBulkDeleteSpec` in 
`grails-data-hibernate7/core` (on #16701), feature "removing one element of a 
set on a join table of its own keeps the other elements", marked 
`@PendingFeature`. It also fails on the base of #16701, so that PR does not 
cause it.
   - Likely cause, not yet confirmed: Hibernate 7's collection persister 
identifies the row to delete by the key columns plus the element columns that 
are *not nullable*, and the binder makes the join table's element column 
nullable. Your observation that Hibernate 5 has the same nullable `role_id` 
column and still adds `and role_id=?` fits that: the difference is in how 
Hibernate 7 builds the row delete, so the fix is either a non-nullable element 
column for a plain set or a row restriction of our own.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to