How can I remove the space before the "n" in the variable y1.
data x;
y='Provider Name ';
y1=catq('1T',y,'n');
put y= y1=;
run;
Are you trying to make a name literal. There is a function for that.
45 data _null_;
46 y='Provider Name ';
47 y1=catq('1T',y,'n');
48 nl = nliteral(y);
49 put y= y1= nl=;
50 run;
y=Provider Name y1='Provider Name' n nl="Provider Name"N
From the documentation of the CATQ function:
If you do not use the C, D, or H modifiers, CATQ uses a blank as a delimiter.
Are you trying to make a name literal. There is a function for that.
45 data _null_;
46 y='Provider Name ';
47 y1=catq('1T',y,'n');
48 nl = nliteral(y);
49 put y= y1= nl=;
50 run;
y=Provider Name y1='Provider Name' n nl="Provider Name"N
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.