Query to find featured products failed: Expression #1 of ORDER BY clause is not in SELECT list, references column 'www_productdb.P.Rank' which is not in SELECT list; this is incompatible with DISTINCT
SELECT DISTINCT P.ProductID, M.AMakeCode, M.SupplierCode, P.ItemN0, P.MainDescription, P.URL, C.ConfiguredID, M.DisplayRetail, C.RetailPrice, C.CustomerPrice, DefaultQuantity, C.ImageTiny, C.WTiny, C.HTiny, SoldOut, DropShipProd, C.FixedShipping FROM www_productdb.Product P INNER JOIN www_productdb.ProductConfigured C USING (ProductID) INNER JOIN www_productdb.SiteProduct S ON P.ProductID = S.ProductID INNER JOIN www_productdb.Make M USING (MakeCode) WHERE DefaultChoice && !C.NoImage && !Discontinue && !SoldOut && S.Site = 'BVN' && Feature ORDER BY Rank LIMIT 20