cast varchar to decimal
Posted on 2008-06-26
one field - varchar(10) - contains a whole bunch of this:
i MUST cast as decimal asap. i tried this:
cast(field as decimal(18,2))
it fails: error converting data type varchar to numeric
i've checked the min/max/avg column lengths. i have this:
min max avg
4 9 4
there are no NULLs, no alpha characters, no negative values
can anyone help?
is anyone able to advise?