First I'd need to know where this mystery number is coming from. Sight unseen, instead of trying to fix broken logic by converting some unknown type to a numeric type, just make sure whatever logic is generating it is generating what you want in the first place.