;WITH cte ([Order#],ReceiptDate) AS (
SELECT [Order#],MAX(ReceiptDate)
FROM
GROUP BY [Order#])
SELECT t.Order#,t.ReceiptDate
FROM cte
JOIN
t ON t.[Order#] = cte.[Order#]
AND t.ReceiptDate >= DATEADD(month,-6,cte.ReceiptDate)
Far away is close at hand in the images of elsewhere.
Anon.