java.lang.ClassCastException: java.lang.Long cannot be cast to java.lang.Int 最简洁的处理办法:
//获取总记录数
String getCountSql = "SELECT COUNT(*) FROM `order`";
Long count = getForValue(connection, getCountSql);
totalRecord = count.intValue();
//获取总记录数
String getCountSql = "SELECT COUNT(*) FROM `order`";
Long count = getForValue(connection, getCountSql);
totalRecord = count.intValue();