I want the last record only for the field pc.[Description]. Should I use the MAX and if so, how do I do it?
SELECT DISTINCT CONVERT(VARCHAR,pv.visit,101) AS DOS,
pv.TicketNumber,
ISNULL(pp.first,'')+ ' '+ ISNULL(pp.last,'')AS [Patient Name],
ISNULL(pp.Address1,'')+ ' '+...