Otherwise, they may crash or be incorrectly verified when creating/updating recordsets containing multiple records. Also improve the constraint error messages to be more detailed. When possible, use a sql constraint instead to speed up the records validation. Task Id: 2328664 COM PR: https://github.com/odoo/odoo/pull/55525 ENT PR: https://github.com/odoo/enterprise/pull/12250