Non penso che tu abbia bisogno del Subquery qui:
SELECT p.customerNumber, MAX(p.amount) AS max
FROM payments p
GROUP BY p.customerNumber
ORDER BY max DESC
LIMIT 1
Non penso che tu abbia bisogno del Subquery qui:
SELECT p.customerNumber, MAX(p.amount) AS max
FROM payments p
GROUP BY p.customerNumber
ORDER BY max DESC
LIMIT 1