【发布时间】:2022-12-27 12:08:45
【问题描述】:
I have a data set that contains year month in column names and I need get the data from column that contains the last date:
data have;
input sdo_202211 sdo_202210 sdo_202209;
datalines;
30 20 10
50 20 30
;
run;
Shape of result:
sdo_202211
30
50
【问题讨论】:
-
What is the shape of your desired result?
-
What are you going to do with a dataset that just has the one variable separated from all of the other variables? Doesn't it lose most of its meaning if you do that?
标签: loops sas filtering calculated-columns sas-macro