I have two tables with common fields (id number and email) I would like to write an update statement that would place the value for field email in table one into field email in table two if field email is empty in table 2 and there is a value in field email in table one.
This is what I tried and it failed miserably.
any one have any idea on how to do this?
Thanks
This is what I tried and it failed miserably.
Code:
UPDATE enrollments SET enrollments.email = einfo.email LEFT JOIN einfo ON einfo.idnumber = enrollments.idnumber WHERE enrollments.email = '' AND einfo.email != ''
any one have any idea on how to do this?
Thanks