corrected table column name
Email function added. not tested