Skip to content

Instantly share code, notes, and snippets.

@cristianciofu
Created July 19, 2013 13:41
Show Gist options
  • Save cristianciofu/6039177 to your computer and use it in GitHub Desktop.
Save cristianciofu/6039177 to your computer and use it in GitHub Desktop.
In case you'll ever need to update a field from a table with a value that's on a different table
UPDATE TABLE1
INNER JOIN TABLE2 ON (TABLE1.field = TABLE2.field)
SET TABLE1.fieldToChange = TABLE2.fieldNewValue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment