You can use a numeric format on a character variable, but that forces SAS to make an automatic conversion.
I'd rather do the conversion explicitly:
x = put(input(x,best.),z5.);
This prevents the NOTE about the conversion in the log and shows the next one who has to maintain the code that you knew what you were doing.
Hint: the next one might be you.
... View more