Chris that looks almost perfect, thank you. (Needed x instead of h in the initial select)
SELECT c.*, x.*
FROM Contact c
OUTER APPLY (
SELECT TOP 1 h.*
FROM History h
WHERE h.Accountno = c.Accountno
ORDER BY h.LastDate DESC
) x
I amended my script, and tested, but our clients dont have a recent backend and they're still a ways off being upgraded. 🙁
OUTER APPLY is new to me, but looks really interesting \ useful. I'll definitely read up on it.
Any suggestions as to how Id be able to get the same results except using scripts for an older backend( SQL 2000 🙁 )?