Files
database/migrations/archive/000.433.sql
T
Rikard BartholfandGitHub ddcbd0afb0 Archive old migrations (#426)
* Archive old migrations

* Fix invalid placement of migrations
2024-10-17 11:19:12 +02:00

26 lines
1.7 KiB
SQL

-- Blacklist week 2 batch (UK and NL for all product groups)
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 1, (select id from markets where name = 'NL') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 2, (select id from markets where name = 'NL') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 3, (select id from markets where name = 'NL') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 7, (select id from markets where name = 'NL') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 1, (select id from markets where name = 'GB') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 2, (select id from markets where name = 'GB') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 3, (select id from markets where name = 'GB') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;
INSERT INTO product_blacklist (product_id, group_id, market_id)
SELECT productid, 7, (select id from markets where name = 'GB') FROM "product-products" WHERE ref3 = 'mJ1Xcd'
ON CONFLICT DO NOTHING;