Last active
October 25, 2018 22:09
-
-
Save robertuniqid/1d368d14d20e810d77df32a097152c1d to your computer and use it in GitHub Desktop.
I would love to be able to take the first 8(?) words of the body and copy them over to the Title
This file contains hidden or 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
UPDATE `wp_posts` SET `post_title` = SUBSTRING_INDEX(PREG_REPLACE('#<[^>]+>#',' ',`post_content`), ' ', 8) | |
WHERE DATE(`post_date`) > '2000-11-11' AND DATE(`post_date`) < '2007-11-11' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment