ITPub博客

首页 > 数据库 > 数据库开发技术 > PostgreSQL: Money与lc_monetary

PostgreSQL: Money与lc_monetary

原创 数据库开发技术 作者:nwpu053871 时间:2016-04-06 16:50:54 0 删除 编辑
[postgres:7440@mutou] [01-08.16:36:29]=# set lc_monetary='zh_CN';
SET
时间:39.176 ms
[postgres:7440@mutou] [01-08.16:37:34]=# show lc_monetary;       
 lc_monetary 
-------------
 zh_CN
(1 行记录)

时间:0.319 ms
[postgres:7440@mutou] [01-08.16:37:36]=# SELECT 12.13::money;
  money  
---------
 ¥12.13
(1 行记录)

时间:13.613 ms
[postgres:7440@mutou] [01-08.16:37:47]=# set lc_monetary='en_US';
SET
时间:0.393 ms
[postgres:7440@mutou] [01-08.16:38:21]=# SELECT 12.13::money;    
 money  
--------
 $12.13
(1 行记录)

时间:6.748 ms
[postgres:7440@mutou] [01-08.16:38:23]=# 

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/22818880/viewspace-2076283/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2009-11-03

  • 博文量
    39
  • 访问量
    75703