0
4 Answers
0
Best Answer
# class miadi_poidsConditionnement(models.Model):
_sql_constraints = [
('uniq_id',
'UNIQUE (produit_id, conditionnement_id)',
'A product already exists with this packaging !')]
Try this
0
Best Answer
check if there is any duplication before applying the constrains , if any one found then i won't take any effect , remove the duplication first then install/upgrade the module