If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Unanswered: Max() with Count()

SELECT A.* FROM (SELECT Custid, Max(EndDate) as Expiry FROM Registrations GROUP BY Custid) X
JOIN Registrations A ON A.Custid=X.custid and A.EndDate=X.Expiry;

It shows for each customer his expiry date.
Now I need to add an extra column showing the count per customer (Count(custid)) but all my attempts have been so far unsuccessful.
Help will be much appreciated.