Hi (again)
I have modified a piece of code (suggested by Chris) that works on its own as a subquery but I am getting the following error;
Only one expression can be specified in the select list when the subquery is not introduced with EXISTS.
I have adapted the query as follows;
SALES.ID,
(SELECT TOP 1 PRODUCT.INFO FROM (SELECT TOP 2 * FROM PRODUCTS WHERE PRODUCTS.ID = SALES.ID AND DESC LIKE 'FLAG SET TO%' ORDER BY DATE DESC) d ORDER BY DATE)
FROM SALES
Any ideas on how I can combat this problem or use "EXISTS"?
Thanks