Created
September 8, 2015 12:32
-
-
Save helix84/c829a7f7fd4607579e6f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- preview change | |
SELECT *, regexp_replace(handle, '123456789/(.*)', E'123/\\1') FROM handle | |
WHERE handle LIKE '123456789/%' | |
LIMIT 50; | |
-- change 123456789/ to 123/ | |
UPDATE handle SET handle = regexp_replace(handle, '123456789/(.*)', E'123/\\1') WHERE handle LIKE '123456789/%'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment