I don't think 'min()' was used correctly in the video
1. self join purchase table, name p1 and p2
2. group by p1.purchase_id
3. use min() to find the earliest purchase record for each purchase record
In the video, we group by p1.purchase_id, thus we should min(p2.purchase_date) instead of min(p1.purchase_date) in order to find the correct 'first_purchase_date'