For version 1.4.0.1  follow the steps…

1.  Take phpMyadmin access from your control panel and select database sql window in order to run following SQL statements

2. We have to insert data in to 3 tables

  1. eav_attribute
  2. catalog_eav_attribute
  3. eav_entity_attribute

Try to replicate already existing table fields with your required changes in id, name and code.

Below i am trying to replicate the description field of category like a second description.

Please note: field values NULL and BLANK have importance , so keep exact same field values when replicating.

INSERT INTO `eav_attribute` (`attribute_id`, `entity_type_id`, `attribute_code`, `attribute_model`, 

`backend_model`, `backend_type`, `backend_table`, `frontend_model`, `frontend_input`, 

`frontend_label`, `frontend_class`, `source_model`, `is_required`, `is_user_defined`, 

`default_value`, `is_unique`, `note`) VALUES('', 9, 'description_second', NULL, '', 'text', '', '', 

'textarea', 'Second Description', NULL, '', 0, 0, '', 0, '');

So here we need to note the new generated row for taking new ‘attribute_id’ , let it be as NEWID.

INSERT INTO `catalog_eav_attribute` (`attribute_id`, `frontend_input_renderer`, `is_global`, `is_visible`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_used_for_price_rules`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, is_configurable`, `apply_to`, `is_visible_in_advanced_search`, `position`, `is_wysiwyg_enabled`) VALUES(981, NULL, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, '', 0, 1, 0);

Here  please note NEWID , you need to replace it with newly generated id from first query.

INSERT INTO `eav_entity_attribute` (`entity_attribute_id` ,`entity_type_id` ,`attribute_set_id` ,`attribute_group_id` ,`attribute_id` ,`sort_order`)
VALUES (NULL , '9', '12', '7', 'NEWID', '2');

Please note NEWID.

Now delete entire cache and re login to admin and check catalog manage area.

For calling in front area

$_category->getData('description_second')

Let me know if have any issue…

© 2014 Developers Corner Suffusion theme by Sayontan Sinha