I have a donations -> donors pair of tables
I need to find the donors who donated during the last 3 years but not yet this year.
I have a date_donated field in donations
This gives me what I need
from donations a
Join donors b on a.kf_donors_id = b.kp_donors_id
Where year (a.date_deposited) in (2016, 2015, 2014) and not year (a.date_deposited) =2017 ";
But I don't know what to do with it
Once I know how I can use to filter the donors i'll replace the hard coded years with calculated values
Can anyone help?