<if test="startTime != null and startTime !=‘‘"> AND lTime >= #{startTime} </if> <if test="endTime != null and endTime !=‘‘"> AND lTime <= #{endTime} </if>
MyBatis中sql实现时间查询的方法
原文:http://www.cnblogs.com/deepbreath/p/5229985.html