title: joining row with most recent date in mysql
body: <p>i'm new to mysql and have been tryn to make this work without any luck.
  i am joining 3 tables and i am tryn to join third table with the row with most recent record as per date.
  here is my mysql query</p>
  
  <pre><code>SELECT mg.region_name, mu.contact_person, 
      mu.contact_number, mu.status, mu.company_name, mu.user_type, MAX(mf.follow_up_date), mf.date, mu.user_id
  FROM p1006_marketing_group as mg 
  JOIN p1006_marketing_users as mu ON mg.id = mu.region_id 
  JOIN ( SELECT user_id_fk,MAX(follow_up_date) 
          FROM p1006_marketing_follow_up ) as mf 
      ON mu.user_id = mf.user_id_fk 
      WHERE mu.user_id_done = "" AND ( mg.id = 3 OR mg.id = 7 OR mg.id = 6 ) 
  GROUP BY mf.user_id_fk
  </code></pre>
  
  <p>i get the following error</p>
  
  <p>Unknown column 'mf.follow_up_date' in 'field list'</p>
  
  <p>i am really confused because i do have to column follow_up_date.</p>
  
  <p>i would be really greateful for any help possible</p>