Generate per-table names for constraint checks.

This commit is contained in:
Nick Tobey
2023-05-10 15:19:07 -07:00
parent 1ecd688929
commit dab974cd5b
+1 -1
View File
@@ -2541,7 +2541,7 @@ func (t *AlterableDoltTable) generateCheckName(ctx *sql.Context, check *sql.Chec
bb.Write([]byte(check.CheckExpression))
hash := hash.Of(bb.Bytes())
hashedName := fmt.Sprintf("chk_%s", hash.String()[:8])
hashedName := fmt.Sprintf("%s_chk_%s", t.tableName, hash.String()[:8])
name := hashedName
var i int