fix: showing a clear message to user about error
This commit is contained in:
parent
e607e3d37e
commit
974f00c771
1 changed files with 2 additions and 0 deletions
|
|
@ -82,5 +82,7 @@ class MariaDBTable(DBTable):
|
|||
fieldname = str(e).split("'")[-2]
|
||||
frappe.throw(_("{0} field cannot be set as unique in {1}, as there are non-unique existing values").format(
|
||||
fieldname, self.table_name))
|
||||
elif e.args[0]==1067:
|
||||
frappe.throw(str(e.args[1]))
|
||||
else:
|
||||
raise e
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue