[Solved] Whats the difference between these two SQL queries?
[ad_1] SUM() is a group function – so that essentially says go get me all the price and quantities by item, and add them all up to return them in one row. MySQL is quite forgiving when grouping things and will try to retrieve a rowset (which is why your second example returns something – … Read more