JAVA: Calendar c = new GregorianCalendar(); log.error("c:"+c); c.set(Calendar.HOUR_OF_DAY,0); c.set(Calendar.MINUTE,0); c.set(Calendar.SECOND,0); c.set(Calendar.MILLISECOND,0); Date start = c.getTime(); log.error("start:"+start); c.set(Calendar.HOUR_OF_DAY,23); c.set(Calendar.MINUTE,59); c.set(Calendar.SECOND,59); c.set(Calendar.MILLISECOND,999); Date end = c.getTime(); log.error("end:"+end); Map<String, Object> m = new HashMap<String, Object>(); m.put("start", start); m.put("end", end); List<FcTargetAssessment> list2 = fcTargetAssessmentMapper.selectByCtime_2(m); log.error("list2:"+list2.toString()); log.error("ta2:"+list2.size()); XML: <select id="selectByCtime_2" resultMap="BaseResultMap"> select <include refid="Base_Column_List" /> from fc_target_assessment_t where ctime >= #{start} and #{end} >= ctime </select>