i install the custom_attribute extension, in that i created a field name like "language" with multi select type, also there have a option to add the select box option values.

i add this field into the edit profile page, after selects the user language i want to display the selected language to some other page.

may i know in which table the options value will be stored.

see the below screen you will be feel better to answer my post.

1)customer custom multi select attribute(language)

enter image description here

2)eav attribute table

enter image description here

3)Customer entity varchar table

enter image description here


In eav_attribute table,

  • All attributes

In eav_attribute_option table,

  • Attributes options with reference to reference attribute_id in eav_attribute table

In eav_attribute_option_value table,

  • Attribute option values with reference to option_id in eav_attribute_option table,

In your customer_entity_varchar table 15,14,13,12 refers to option_id in eav_attribute_option table and you can refer the labels for 15,14,13,12 in eav_attribute_option_value table

To get the values like array(12=>'Portuguese',13=>'spanish',14=>'hindi',15=>'tamil')

     * @var $config  Mage_Eav_Model_Config
     * @var $options Mage_Eav_Model_Resource_Entity_Attribute_Option_Collection
    $storeId   = Mage::app()->getStore()->getId();
    $config    = Mage::getModel('eav/config');
    $attribute = $config->getAttribute(Mage_Catalog_Model_Product::ENTITY, 'color');
    $values    = $attribute->setStoreId($storeId)->getSource()->getAllOptions();

    //here is another method
    $options = Mage::getResourceModel('eav/entity_attribute_option_collection');
    $values  = $options->setAttributeFilter($attribute->getId())->setStoreFilter($storeId)->toOptionArray();
  • i got it your answer,but i want this like array(12=>'Portuguese',13=>'spanish',14=>'hindi',15=>'tamil'), how can i achieve this
    – senthil
    Jul 8 '15 at 6:09
  • I have updated the answer Jul 8 '15 at 6:23
  • How to use this for customer/address? @saravanavelu I try change Mage_Catalog_Model_Product for Mage_Customer_Model_Address, but don't work, you can help me? Nov 14 '17 at 16:27
  • @saravanavelu See this magento.stackexchange.com/questions/201483/… Nov 14 '17 at 16:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.