Ananth@Sql (5/24/2013)
I have a column and the values are 0.01
0.2
0.0003
0.00004
0.5
I want output like this
1
2
3
4
5
please share your thoughts?
You are not new here, surely you could present your question in a more helpful way (DDL and data)
SELECT CAST(REPLACE(CAST(V AS VARCHAR(20)),'0','') * 10.0 AS INT)
FROM (VALUES (0.01),(0.2),(0.0003),(0.00004),(0.5)) V(V)
_____________________________________________
"The only true wisdom is in knowing you know nothing"
"O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
(So many miracle inventions provided by MS to us...)
How to post your question to get the best and quick help[/url]