From: Vineet Punnoose on
Hello Everyone,

I have a particular problem which i am not able to find any solution
anywhere.

I have a sql database where the individual id is a 20 digit long
number. When i download it to SAS the last four digits of the number
change arbitrarily to anything, because of which i am not able to
merge with another table.

I tried the put command while using proc sql to change the format but
that also does not help.

is there a way where i can change the type of the variable to char
from numeric in the import data step itself.
From: Reeza on
On Apr 9, 8:35 am, Vineet Punnoose <vineet.punno...(a)gmail.com> wrote:
> Hello Everyone,
>
> I have a particular problem which i am not able to find any solution
> anywhere.
>
> I have a sql database where the individual id is a 20 digit long
> number. When i download it to SAS the last four digits of the number
> change arbitrarily to anything, because of which i am not able to
> merge with another table.
>
> I tried the put command while using proc sql to change the format but
> that also does not help.
>
> is there a way where i can change the type of the variable to char
> from numeric in the import data step itself.

how are you importing the data?

If you're using a passthrough sql statement does convert(varchar(20),
fieldname) as longid in the sql import statement help?