postgresql to_char integer to string

最近用到了postgresql中的to_char将数字转为字符串,现将官网的实例搜集以下sql

wKioL1PXWUrBdQSxAAQeY2_oZAM247.jpg

除了以上功能外,to_char还有四舍五入的功能ide

select to_char(3.005,'0.99')

返回3.01post

select to_char(3.003,'0.99')

返回的是3.00postgresql

好了有啥问题直接流言一超交流blog

相关文章
相关标签/搜索