Oracle 查询某一段时间内的数据
between to_timestamp(#{startCreateDate} || \' 00:00:00\',\'yyyy-mm-dd hh24:mi:ss\') and to_timestamp(#{endCreateDate} || \' 23:59:59\',\'yyyy-mm-dd hh24:mi:ss\')
注:startCreateDate 和 endCreateDate 传入的值应为年月日,不可加时分秒,不然字符串拼接会出错
between to_timestamp(#{startCreateDate} || \' 00:00:00\',\'yyyy-mm-dd hh24:mi:ss\') and to_timestamp(#{endCreateDate} || \' 23:59:59\',\'yyyy-mm-dd hh24:mi:ss\')
注:startCreateDate 和 endCreateDate 传入的值应为年月日,不可加时分秒,不然字符串拼接会出错
相关文章: