PASTEBIN
| #1 paste tool since 2002
create new paste
tools
api
archive
faq
PASTEBIN
create new paste
trending pastes
sign up
login
my alerts
my settings
my profile
Don't like ads?
PRO users
don't see any ads ;-)
Public Pastes
Untitled
0 sec ago
Untitled
0 sec ago
Untitled
Java | 2 sec ago
Untitled
2 sec ago
Untitled
4 sec ago
Untitled
C | 5 sec ago
Untitled
6 sec ago
Untitled
17 sec ago
Format SQL Number
By:
andrew4582
on
Dec 4th, 2011
| syntax:
T-SQL
| size: 0.08 KB | hits: 106 | expires: Never
download
|
raw
|
embed
|
report abuse
|
print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
SELECT
REPLACE
(
CONVERT
(
varchar
(
20
)
,
(
CAST
(
123448.9766
AS
money
)
)
,
1
)
,
'.00'
,
''
)
create a
new version
of this paste
RAW Paste Data
SELECT REPLACE(CONVERT(varchar(20), (CAST(123448.9766 AS money)), 1), '.00', '')