2025年02月04日 建站教程
如何利用mysql语法保留3位小数点,不足补0?下面web建站小编给大家简单介绍一下具体代码!
方法一:利用format
实现
select format('12343242.1',3) as value from dual
方法二:利用round
实现
select cast(round(ifnull('12343242.1','0.000'),3) as char) as value
本文链接:http://so.lmcjl.com/news/22586/