星空网 > 软件开发 > 数据库

mysql中取系统当前时间

<select id="getFreightEfclInventoryList" parameterType="long" resultMap="BaseResultMap1">
  SELECT
  freight_efcl_inventory_id,
  freight_efcl_id,
  closing_date,
  sailing_date,
  shipping_space_total,
  shipping_space_remain,
  shipping_space_used
  FROM
  freight_efcl_inventory
  WHERE
  1=1
  AND freight_efcl_id=#{freightEfclId}
  AND sailing_date >= DATE(current_timestamp)
  ORDER BY
  sailing_date ASC
  limit 4
  </select>

 注意:sailing_date字段类型是Date类型,系统当前时间current_timestamp时间格式带时分秒的,所以需要将其转换成Date类型。

 




原标题:mysql中取系统当前时间

关键词:MYSQL

*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们: admin#shaoqun.com (#换成@)。
相关文章
我的浏览记录
最新相关资讯
海外公司注册 | 跨境电商服务平台 | 深圳旅行社 | 东南亚物流