How To Fix SM Megamenu Error When Update To Magento v1.9.2.0

When Updating ( or installing) your Magento theme to Version, and you had problem with error of SQL state, and you want to fix it as soon as posible.

When you try to view my menu items in backend, you have an error:

a:5:{i:0;s:662:"SQLSTATE[42S22]: Column not found: 1054 Unknown column 'CONCAT( REPEAT( "--- ", (COUNT(parent.depth) - 1) ) , main_table.title)' in 'field list', query was: SELECT `main_table`.*, `mgroup`.`title` AS `group_name`, `CONCAT( REPEAT( "--- ", (COUNT(parent.depth) - 1) ) , main_table`.`title)` AS `name` FROM `sm_menu_items` AS `main_table`
INNER JOIN `sm_menu_groups` AS `mgroup` ON = main_table.group_id
CROSS JOIN `sm_menu_items` AS `parent` WHERE (main_table.lft BETWEEN parent.lft AND parent.rgt) AND (parent.group_id = main_table.group_id) GROUP BY `main_table`.`id` ORDER BY `main_table`.`group_id` ASC, `main_table`.`lft` ASC, id ASC LIMIT 20";i:1;s:6219:"#0

This tutorial, we will guide you how to fix it to help your store in Magento

All you need to fix the issue with mega menu is to do as 4 following steps to fix SQL state:

Step 1:Go to file app\code\local\Sm\Megamenu\Block\Adminhtml\Menuitems\Grid.php and back up this file.

Step 2:In this file app\code\local\Sm\Megamenu\Block\Adminhtml\Menuitems\Grid.php please go to line 39 and edit it into:

->columns(new Zend_Db_Expr('CONCAT( REPEAT( "'.Sm_Megamenu_Model_System_Config_Source_Prefix::PREFIX.' ", (COUNT(parent.depth) - 1) ) , main_table.title) AS name'))

Step 3: Please go to file app\code\local\Sm\Megamenu\Helper\Data.php and back up this file.

Step 4: In this file app\code\local\Sm\Megamenu\Helper\Data.php. please edit line 320 into:

->columns(new Zend_Db_Expr('CONCAT( REPEAT( "'.$prefix.'", (COUNT(parent.depth) - 1) ) , main_table.title) AS name'))

Step 5: After that you can clear cache, log out and log in your admin and you should be able to use your menu again.

Thanks abunch for reading!