Code Room
Code reviewHard
Question
Review this SQL meant to show each product's latest price and total units sold.
This runs on MySQL with `ONLY_FULL_GROUP_BY` disabled.
What a strong answer looks like
Separate real bugs from style. Rank issues by severity, point at the root cause rather than the symptom, and suggest a concrete fix — specific and kind.
Learn the concepts
SELECT p.category, p.name, p.price, SUM(s.units) AS units_soldFROM products pJOIN sales s ON s.product_id = p.idGROUP BY p.category;Run or narrate your approach, then ask the coach.