Hi all,

I am working on a database where each subject is identified by -id- and each visit by -visit-. The data are long. There are several visits for each id.

I am struggling finding a code to specifically identify the last visit for each subject. Of course, they don't have the same numbers of visits. I think very easy but ii can't find how to do that.

Thank you very much in advance,

CLY