Created
February 17, 2016 20:56
-
-
Save molotovbliss/d2fd9bdf87fa0d12b121 to your computer and use it in GitHub Desktop.
Assign a New Attribute to All Attribute Sets
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
INSERT INTO `eav_entity_attribute` ( | |
`entity_type_id`, | |
`attribute_set_id`, | |
`attribute_group_id`, | |
`attribute_id`, | |
`sort_order` | |
) | |
( | |
SELECT | |
'ENTITY_TYPE_ID' AS entity_type_id, | |
`attribute_set_id`, | |
`attribute_group_id`, | |
`attribute_id`, | |
'SORT_ORDER' AS `sort_order` | |
FROM `eav_attribute_group`, `eav_attribute` | |
WHERE `attribute_group_name` = 'General' | |
AND `attribute_code` = 'ATTRIBUTE_CODE' | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment