Проблема с CAST

minya13_85

Microsoft SQL Server 2005 - 9.00.4053.00 (X64) May 26 2009 14:13:01 Copyright (c) 1988-2005 Microsoft Corporation Enterprise Edition (64-bit) on Windows NT 5.2 (Build 3790: Service Pack 2)
declare @d float
set @d=<b>1170548</b>.<b>59</b>
select cast(@d as varchar)+' ' + 'оплата' as d


выводит какую-то хрень:
<b>1</b>.17055e+<b>006</b> оплата

а как вывести: 
<b>1170548</b>.<b>59</b> оплата
3 ответа

minya13_85

select cast(cast(@d as decimal(18,2)) as varchar)+' ' + 'оплата' as d


minya13_85

select cast(cast(@d as decimal(18,2)) as varchar)+' ' + 'оплата' as d
ок спасибо..


minya13_85

declare @d float
set @d=<b>1170548</b>.<b>59</b>
select str(@d,<b>20</b>,<b>2</b>)+' ' + 'оплата' as d