mirror of
https://gitee.com/mybatis-flex/mybatis-flex.git
synced 2025-12-06 16:48:24 +08:00
feat: 新增判断数据库操作是否成功方法
This commit is contained in:
parent
2116dff818
commit
50657584c1
@ -62,4 +62,15 @@ public class SqlUtil {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 根据数据库响应结果判断数据库操作是否成功。
|
||||
*
|
||||
* @param result 数据库操作返回影响条数
|
||||
* @return {@code true} 操作成功,{@code false} 操作失败。
|
||||
*/
|
||||
public static boolean retBool(int result) {
|
||||
return result >= 1;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user