使用STR( float_expression [ , length [ , decimal ] ] )函数
如str(1.23000,4)='1.23'
str(1.23000,4,1)='1.2'
str(1.27000,4,1)='1.3'
str(1.23000,6,3)='1.230'
如str(1.23000,4)='1.23'
str(1.23000,4,1)='1.2'
str(1.27000,4,1)='1.3'
str(1.23000,6,3)='1.230'
Set @p=1.2300
Select Cast(Cast(@p as Float) as Varchar) as Result