Assuming your variable is character this is one way:
data have;
input id $;
datalines;
000342
000562
001342
001452
000322
;
data want;
set have;
id = cats(substr(id,1,length(id)-1),'1');
run;
@Smitha9 wrote:
Hi I want to delete the last digit and replace with 1
ID
000342
000562
001342
001452
000322
I want:
000341
000561
001341
001451
000321
thanks in advance.