mysql---使用limit作为分页查询
ew = new EntityWrapper<>(); ew.in("c_type", ids); if (name != null) { ew.like("c_name", name); } if (code != null) { ew.like("c_code", code); } if (state != null) { ew.eq("n_state", state); } ew.orderBy("n_sort"); //pageNum 当前页
//pageSize 每页显示条数
if (pageNum != null && pageSize != null) { ew.last("limit " + (pageNum - 1) * pageSize + "," + pageSize); }