I have a membership-table with userid as primary key.
I have another table (table A) containing two foreign keys to the membership-table (tableA.userid1 and tableA.userid2).
Now I want to update the emailadress inside the membership-table of userid2 with the emailadress of userid1.
How can I do that? Something like...
Update membership m2
set m2.email = m1.email
...???