Hi,
Mysql has a nice non-standard SQL feature called GROUP by with hidden fields.
http://dev.mysql.com/doc/mysql/en/group-by-hidden-fields.html
If you were to run your query in any other RDBMS, it would complain that a.amount and b.price are not included in the GROUP BY statement. Mysql treats them as 'hidden' fields and includes them in the output. However, if multiple values exist for the a.product_id, b.currency_id, and max( b.active_date ) combination, you will get unpredictable results.
Generally you should include all columns in the GROUP BY clause that do not include a summary function (max(), min(), sum(), count(). etc.)
GROUP BY a.product_id, a.amount_id, b.currency_id, b.price
Chris