SQL Query . Get all product attributes with “Attribute Sets” And “Attribute Groups”


select
eas.attribute_set_name,
eag.attribute_group_name,
ea.attribute_code,
eea.sort_order,
cea.*

from eav_attribute as ea
inner join catalog_eav_attribute as cea on cea.attribute_id = ea.attribute_id
left join eav_entity_attribute as eea on eea.attribute_id = ea.attribute_id
left join eav_attribute_set as eas on eas.attribute_set_id = eea.attribute_set_id
left join eav_attribute_group as eag on eag.attribute_group_id = eea.attribute_group_id
where ea.entity_type_id = 4
and eas.attribute_set_name = ‘bundle’
order by
eas.attribute_set_name asc,
eag.attribute_group_name asc;