mysql 字符串转换成数字

在mysql中使用cast 函数将数字转换字符时,发现这样一个现象,将字符串“6,666”转换为数字时,预期值应该为6666,但实际值为6,并且rails的1.22版本也存在同样的问题。

解决方法,很无奈,将“6,666”中的”,”去掉,再进行转换。

您可能感兴趣的文章

  1. mysql不能启动 Manager of pid-file quit without updating file.
  2. ruby 中 include 与 extend 区别
  3. 安装Rmagick
  4. rails3.0 安装mysql2 失败,发生lmysqlclient 错误
  5. mysql 横向扩展性
  6. ruby 安装 rmagick
  7. MySql用户创建、授权以及删除
  8. MySQL中的mysqldump命令使用详解
  9. ruby与rails版本差异不能连接mysql
  10. 安装 Sphinx
分享到Twitter 分享到新浪微博 分享到开心 分享到QQ空间 分享到人人 分享到鲜果 分享到豆瓣 分享到网易微博 分享到搜狐微博
You can leave a response, or trackback from your own site.

Leave a Reply

You must be logged in to post a comment.

Powered by WordPress | Find Wireless Deals at BestInCellPhones.com. | Thanks to iCellPhoneDeals.com Free Cell Phones, Find Highest CD Rates and Incinerador De Grasa Revisión