Last active
April 3, 2018 06:00
-
-
Save canabady/899f539890e1f27b9914c65a6b748643 to your computer and use it in GitHub Desktop.
If you want to replace path in images for WooProduct kept in sqlite
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
If you want to replace path in images for WooProduct kept in sqlite | |
=================================================================== | |
The replace ((())) does extract filename from the existing path in the images | |
columsn and we add base path of the server folder for accesss | |
SQLITE Query command is as below | |
-------------------------------- | |
UPDATE local_wc_product SET Images = 'http://wordpress.com/wp-content/uploads/2018/04/' || replace(images, rtrim(images, replace(images, '/', '')),'') WHERE Images IS NOT NULL; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment