我想在MySQL数据库中得到当前的时间,并且精度精确到毫秒,有什么办法能解决吗?
时间的精度如何取到毫秒呢?select date_format(current_timestamp,'%y-%m-%d %h:%i:%s:%f');
这样取的话时间只能精确到秒!
09-01-08 03:13:57:000000哪位大侠快点帮帮我吧!小妹在此有礼了!

解决方案 »

  1.   

    select now() as Systime; 
    select current_date as Systime; 
    select sysdate() as Systime; 试试看
      

  2.   


    这个我试了,出现错误提示如下
    mysql> SELECT CONVERT(varchar(30), GETDATE(),121);
    ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that
    corresponds to your MySQL server version for the right syntax to use near 'varch
    ar(30), GETDATE(),121)' at line 1这是什么意思?是我的MySQL的版本有问题吗?