MySQL和PostgreSQL的日期格式化

MySQL和PostgreSQL的日期格MySQL:

select DATE_FORMAT(CURRENT_TIMESTAMP,'%Y-%m-%d %H:%i:%s') AS col1,CURRENT_TIMESTAMP as col2



PostgreSQL:

select to_char(CURRENT_TIMESTAMP,'yyyy-mm-dd hh24:mi:ss') AS col1,CURRENT_TIMESTAMP as col2式化

你可能感兴趣的:(PostgreSQL)