This commit is contained in:
shoopea 2019-06-25 17:39:11 +08:00
parent 901361e0bf
commit af51f5ec9b

2
obj.go
View File

@ -69,7 +69,7 @@ func objAddName(objID64 int64, name string) error {
stmt, err := db.Prepare(`INSERT INTO obj_name (obj_id, name, priority)
SELECT ? obj_id, ? name, (SELECT MAX(priority) + 1 FROM obj_name WHERE obj_id = ?) priority FROM DUAL;`)
_, err := stmt.Exec(objID64, name, objID64)
_, err = stmt.Exec(objID64, name, objID64)
return err
}