Skip to content

Instantly share code, notes, and snippets.

View anton-roos's full-sized avatar
🎯
Focusing

Anton Roos anton-roos

🎯
Focusing
View GitHub Profile
@anton-roos
anton-roos / update-sold-individually.sql
Last active May 25, 2020 14:47
Update Sold Individually of all WooCommerce products.
UPDATE `wp_postmeta`
SET `meta_value` = 'no'
WHERE `meta_key` = '_sold_individually'
@anton-roos
anton-roos / select-duplicate-skus.sql
Last active May 25, 2020 14:41
Select duplicate SKUs from WooCommerce database.
SELECT meta_value
FROM wp_postmeta
WHERE meta_key = '_sku'
AND meta_value != ''
GROUP BY meta_value HAVING COUNT(meta_value) > 1
@anton-roos
anton-roos / sendy.sql
Last active April 9, 2020 10:18
Sendy SQL Queries
/* Delete all bounced email addresses from list 13 */
DELETE FROM `subscribers` WHERE `bounced` = 1 AND `list` = 13;
/* Delete all marked as spam email addresses from list 5 */
DELETE FROM `subscribers` WHERE `complaint` = 1 AND `list` = 5;