摘要:
Postgres 格式化函数提供一套有效的工具用于把各种数据类型(日期/时间,int,float,numeric)转换成格式化的字符串以及反过来从格式化的字符串转换成原始的数据类型。注意:所有格式化函数的第二个参数是用于转换的模板。表 5-7. 格式化函数函数返回描述例子to_char(timestamp, text)text把 timestamp 转换成 stringto_char(timestamp 'now','HH12:MI:SS')to_char(int, text)text把 int4/int8 转换成 stringto_char(125, ' 阅读全文
posted @ 2013-03-28 11:22
ip-10000
阅读(984)
评论(0)
推荐(0)