Guest User

Untitled

a guest
Apr 26th, 2018
903
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. Table A
  2. address_id email
  3. 12341 aba@mail.com
  4. 12342 abb@mail.com
  5. 12343 abc@mail.com
  6. 12344 abd@mail.com
  7. 12345 abe@mail.com
  8. 12346 abf@mail.com
  9. 12347 abg@mail.com
  10. 12348 abh@mail.com
  11. 12349 abi@mail.com
  12.  
  13. Table B
  14. address_id email
  15. 12342 xyz@mail.com
  16. 12344 xyy@mail.com
  17. 12349 xyx@mail.com
  18.  
  19. update TableA A set email=(select email from TableB B where A.address_id=B.address_id)
Add Comment
Please, Sign In to add comment