Ollivander's Inventory

  • + 2 comments

    Can you please explain how

    W.coins_needed = 
    (SELECT MIN(coins_needed)
    FROM WANDS AS W1
    INNER JOIN WANDS_PROPERTY AS P1 ON W1.code = P1.code
    WHERE W1.power = W.power AND P1.age = P.age)
    

    is different than

    group by W.power, W.age
    having MIN(W.coins_needed)
    

    Thanks