If this is MS SQL Server that takes the first observation for each player_id, according to the sort order after the ORDER BY statement. An equivalent in SAS would be a "first." operation on a sorted datastep, like: PROC SORT DATA=DS1 BY player_id DESCENDING completion_dte plan; RUN; DATA DS2; SET DS1; BY player_id DESCENDING completion_dte plan; if first.player_id then output; RUN; I might have the "DESCENDING" in the wrong place, I usually do.
... View more