SELECT MIN(buyPrice) FROM products;
SELECT productCode, productName, buyPrice FROM products WHERE buyPrice = ( SELECT MIN(buyPrice) FROM products);
SELECT productline, MIN(buyprice) FROM products GROUP BY productline;
SELECT productline, productCode, productName, buyprice FROM products a WHERE buyprice = ( SELECT MIN(buyprice) FROM products b WHERE b.productline = a.productline);
SELECT a.productline, a.productCode, a.productName, a.buyprice FROM products a LEFT JOIN products b ON a.productline = b.productline AND b.buyprice < a.buyprice WHERE b.productcode IS NULL;