mirror of
https://gitee.com/ssssssss-team/magic-api.git
synced 2026-09-03 13:18:12 +08:00
Merge pull request #113 from Sajor-X/bug-fix
修复主键为字符情况Data truncation失败问题
This commit is contained in:
@@ -424,7 +424,7 @@ public class NamedTable extends Attributes<Object> {
|
||||
params.addAll(where.getParams());
|
||||
} else if (primaryValue != null) {
|
||||
builder.append(" where ").append(this.primary).append(" = ?");
|
||||
params.add(primaryValue);
|
||||
params.add(String.valueOf(primaryValue));
|
||||
} else {
|
||||
throw new MagicAPIException("主键值不能为空");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user