zoukankan      html  css  js  c++  java
  • mysql保存当前时间精确到秒

       用mybatis在mysql中保存字段精确到秒须要两个步骤。

    1、如今mysql中将时间字段改为datetime 比如:alter table tablename add pay_date datetime comment '精确到秒的时间'

    2、在sql语句中直接用now().  比如:        update tj_record set   is_customerHandover ='1' and customer_handover_date = now() where id = #{record_id}



查看全文
  • 相关阅读:
    hdu 1124 OR toj 1065 简单数论
    this和判断的位置对赋值的要求
    快捷键操作
    常量池和堆的区别
    toString的用法
    使用泛型解决之前的问题
    不使用泛型会运行时会出现的问题
    集合图型
    代码块运行的优先级
    遍历集合的Iterator删除其中的元素
  • 原文地址:https://www.cnblogs.com/ldxsuanfa/p/10842351.html
  • Copyright © 2011-2022 走看看