如何获取 Sqlite 中的当前时间戳?current_time、current_date、current_timestamp 都返回格式化日期,而不是 long。
sqlite> insert into events (timestamp) values (current_timestamp);
sqlite> insert into events (timestamp) values (current_date);
sqlite> insert into events (timestamp) values (current_time);
sqlite> select * from events;
1|2010-09-11 23:18:38
2|2010-09-11
3|23:18:51
我想要的是:
4|23234232