I am trying to get the average and last date row from a table that has duplications of rows for the same ID, for example:
Table:
ID VisitID Date Value
1 1 10-10-2001 1
2 1 10-11-2001 1
1 2 10-11-2001 3
OUT PUT
Table:
ID VisitID Date Value
1 1 10-11-2001 ***(max date)*** 2 (***total of the two date / number of rows)***
2 1 10-11-2001 1
Thanks in advance.
is what I think you want, unless I’m missing the question.