hi,
suppose that I have the following table already sorted in this specific way:
company | date | number |
---|---|---|
A | 31/11/2010 | 1 |
A | 31/11/2010 | 2 |
B | 22/1/2009 | 2 |
C | 1/1/2008 | 1 |
I just need the first row for each company-date combination so that the final result is:
company | date | number |
---|---|---|
A | 31/11/2010 | 1 |
B | 22/1/2009 | 2 |
C | 1/1/2008 | 1 |
thank you!
omg this is so simple that I just didn't think about it, I just do proc sort with nodupkey by company and date!!
omg this is so simple that I just didn't think about it, I just do proc sort with nodupkey by company and date!!
Thanks for coming back to post your solution, ilikesas!
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.
Find more tutorials on the SAS Users YouTube channel.