ALTER TABLE product_assets
    ADD COLUMN asset_role VARCHAR(50) NOT NULL DEFAULT 'gallery' AFTER asset_type;

ALTER TABLE shop_product_assets
    ADD COLUMN asset_role VARCHAR(50) NOT NULL DEFAULT 'gallery' AFTER asset_type;

UPDATE product_assets
SET asset_role = 'cover'
WHERE asset_type = 'image'
  AND position = 1
  AND asset_role = 'gallery';

UPDATE shop_product_assets
SET asset_role = 'cover'
WHERE asset_type = 'image'
  AND position = 1
  AND asset_role = 'gallery';
