1

I'm trying to upgrade a CiviCRM 4.7.9 installation to 4.7.14 and the following errors happen during the upgrade process. This site is also using internationalization, but I've made sure the localization files are in place properly.

Dec 24 09:50:45  [info] Running task: Upgrade DB to 4.7.11: SQL

Dec 24 09:51:06  [info] Running task: Dashboard schema updates

Dec 24 09:51:33  [info] $Fatal Error Details = Array
(
    [callback] => Array
        (
            [0] => CRM_Core_Error
            [1] => exceptionHandler
        )

    [code] => -19
    [message] => DB Error: no such field
    [mode] => 16
    [debug_info] => CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm_dashboard_contact FOR EACH ROW BEGIN  IF ( @civicrm_disable_logging IS NULL OR @civicrm_disable_logging = 0 ) THEN INSERT INTO log_civicrm_dashboard_contact (id, dashboard_id, contact_id, column_no, is_minimized, is_fullscreen, is_active, weight, created_date, log_conn_id, log_user_id, log_action) VALUES ( NEW.id, NEW.dashboard_id, NEW.contact_id, NEW.column_no, NEW.is_minimized, NEW.is_fullscreen, NEW.is_active, NEW.weight, NEW.created_date, COALESCE(@uniqueID, LEFT(CONCAT('c_', unix_timestamp()/3600, CONNECTION_ID()), 17)), @civicrm_user_id, 'insert'); END IF; END [nativecode=1054 ** Unknown column 'is_minimized' in 'NEW']
    [type] => DB_Error
    [user_info] => CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm_dashboard_contact FOR EACH ROW BEGIN  IF ( @civicrm_disable_logging IS NULL OR @civicrm_disable_logging = 0 ) THEN INSERT INTO log_civicrm_dashboard_contact (id, dashboard_id, contact_id, column_no, is_minimized, is_fullscreen, is_active, weight, created_date, log_conn_id, log_user_id, log_action) VALUES ( NEW.id, NEW.dashboard_id, NEW.contact_id, NEW.column_no, NEW.is_minimized, NEW.is_fullscreen, NEW.is_active, NEW.weight, NEW.created_date, COALESCE(@uniqueID, LEFT(CONCAT('c_', unix_timestamp()/3600, CONNECTION_ID()), 17)), @civicrm_user_id, 'insert'); END IF; END [nativecode=1054 ** Unknown column 'is_minimized' in 'NEW']
    [to_string] => [db_error: message="DB Error: no such field" code=-19 mode=callback callback=CRM_Core_Error::exceptionHandler prefix="" info="CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm_dashboard_contact FOR EACH ROW BEGIN  IF ( @civicrm_disable_logging IS NULL OR @civicrm_disable_logging = 0 ) THEN INSERT INTO log_civicrm_dashboard_contact (id, dashboard_id, contact_id, column_no, is_minimized, is_fullscreen, is_active, weight, created_date, log_conn_id, log_user_id, log_action) VALUES ( NEW.id, NEW.dashboard_id, NEW.contact_id, NEW.column_no, NEW.is_minimized, NEW.is_fullscreen, NEW.is_active, NEW.weight, NEW.created_date, COALESCE(@uniqueID, LEFT(CONCAT('c_', unix_timestamp()/3600, CONNECTION_ID()), 17)), @civicrm_user_id, 'insert'); END IF; END [nativecode=1054 ** Unknown column 'is_minimized' in 'NEW']"]
)


Dec 24 09:51:33  [info] $backTrace = #0 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Error.php(932): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 [internal function](): CRM_Core_Error::exceptionHandler(Object(DB_Error))
#2 /var/www/html/sites/all/modules/contrib/civicrm/packages/PEAR.php(921): call_user_func((Array:2), Object(DB_Error))
#3 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB.php(985): PEAR_Error->__construct("DB Error: no such field", -19, 16, (Array:2), "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#4 /var/www/html/sites/all/modules/contrib/civicrm/packages/PEAR.php(575): DB_Error->__construct(-19, 16, (Array:2), "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#5 [internal function](): PEAR->_raiseError(Object(DB_mysqli), NULL, -19, NULL, NULL, "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", "DB_Error", TRUE)
#6 /var/www/html/sites/all/modules/contrib/civicrm/packages/PEAR.php(224): call_user_func_array((Array:2), (Array:8))
#7 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/common.php(1905): PEAR->__call("raiseError", (Array:7))
#8 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/common.php(1905): PEAR->raiseError(NULL, -19, NULL, NULL, "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", "DB_Error", TRUE)
#9 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/mysqli.php(933): DB_common->raiseError(-19, NULL, NULL, NULL, "1054 ** Unknown column 'is_minimized' in 'NEW'")
#10 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/mysqli.php(403): DB_mysqli->mysqliRaiseError()
#11 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/common.php(1216): DB_mysqli->simpleQuery("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#12 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/DataObject.php(2438): DB_common->query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#13 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/DataObject.php(1627): DB_DataObject->_query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#14 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/DAO.php(354): DB_DataObject->query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#15 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/DAO.php(1297): CRM_Core_DAO->query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", FALSE)
#16 /var/www/html/sites/all/modules/contrib/civicrm/Civi/Core/SqlTriggers.php(225): CRM_Core_DAO::executeQuery("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", (Array:0), TRUE, NULL, FALSE, FALSE)
#17 /var/www/html/sites/all/modules/contrib/civicrm/Civi/Core/SqlTriggers.php(171): Civi\Core\SqlTriggers->enqueueQuery("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#18 /var/www/html/sites/all/modules/contrib/civicrm/Civi/Core/SqlTriggers.php(70): Civi\Core\SqlTriggers->createTriggers((Array:486), NULL)
#19 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/DAO.php(1975): Civi\Core\SqlTriggers->rebuild(NULL, FALSE)
#20 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/I18n/Schema.php(352): CRM_Core_DAO::triggerRebuild()
#21 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/BAO/SchemaHandler.php(389): CRM_Core_I18n_Schema::rebuildMultilingualSchema((Array:3), NULL)
#22 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Upgrade/Incremental/php/FourSeven.php(829): CRM_Core_BAO_SchemaHandler::dropColumn("civicrm_dashboard_contact", "is_minimized")
#23 [internal function](): CRM_Upgrade_Incremental_php_FourSeven::dashboardSchemaUpdate(Object(CRM_Queue_TaskContext))
#24 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Task.php(88): call_user_func_array((Array:2), (Array:1))
#25 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Runner.php(214): CRM_Queue_Task->run(Object(CRM_Queue_TaskContext))
#26 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Page/AJAX.php(52): CRM_Queue_Runner->runNext(TRUE)
#27 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/ErrorPolicy.php(106): CRM_Queue_Page_AJAX::{closure}()
#28 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Page/AJAX.php(54): CRM_Queue_ErrorPolicy->call(Object(Closure))
#29 [internal function](): CRM_Queue_Page_AJAX::runNext()
#30 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Invoke.php(276): call_user_func((Array:2))
#31 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Invoke.php(84): CRM_Core_Invoke::runItem((Array:13))
#32 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Invoke.php(52): CRM_Core_Invoke::_invoke((Array:5))
#33 /var/www/html/sites/all/modules/contrib/civicrm/drupal/civicrm.module(448): CRM_Core_Invoke::invoke((Array:5))
#34 [internal function](): civicrm_invoke("upgrade", "queue", "ajax", "runNext")
#35 /var/www/html/includes/menu.inc(527): call_user_func_array("civicrm_invoke", (Array:4))
#36 /var/www/html/index.php(21): menu_execute_active_handler()
#37 {main}


Dec 24 09:51:33  [info] $CRM_Queue_Page_AJAX_runNext_error = PEAR_Exception: "DB Error: no such field"
 * ERROR TYPE: DB_Error
 * ERROR CODE: -19
 * ERROR MESSAGE: DB Error: no such field
 * ERROR MODE: 16
 * ERROR USERINFO: CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm_dashboard_contact FOR EACH ROW BEGIN  IF ( @civicrm_disable_logging IS NULL OR @civicrm_disable_logging = 0 ) THEN INSERT INTO log_civicrm_dashboard_contact (id, dashboard_id, contact_id, column_no, is_minimized, is_fullscreen, is_active, weight, created_date, log_conn_id, log_user_id, log_action) VALUES ( NEW.id, NEW.dashboard_id, NEW.contact_id, NEW.column_no, NEW.is_minimized, NEW.is_fullscreen, NEW.is_active, NEW.weight, NEW.created_date, COALESCE(@uniqueID, LEFT(CONCAT('c_', unix_timestamp()/3600, CONNECTION_ID()), 17)), @civicrm_user_id, 'insert'); END IF; END [nativecode=1054 ** Unknown column 'is_minimized' in 'NEW']
 * ERROR DEBUGINFO: CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm_dashboard_contact FOR EACH ROW BEGIN  IF ( @civicrm_disable_logging IS NULL OR @civicrm_disable_logging = 0 ) THEN INSERT INTO log_civicrm_dashboard_contact (id, dashboard_id, contact_id, column_no, is_minimized, is_fullscreen, is_active, weight, created_date, log_conn_id, log_user_id, log_action) VALUES ( NEW.id, NEW.dashboard_id, NEW.contact_id, NEW.column_no, NEW.is_minimized, NEW.is_fullscreen, NEW.is_active, NEW.weight, NEW.created_date, COALESCE(@uniqueID, LEFT(CONCAT('c_', unix_timestamp()/3600, CONNECTION_ID()), 17)), @civicrm_user_id, 'insert'); END IF; END [nativecode=1054 ** Unknown column 'is_minimized' in 'NEW']
#0 [internal function](): CRM_Core_Error::exceptionHandler(Object(DB_Error))
#1 /var/www/html/sites/all/modules/contrib/civicrm/packages/PEAR.php(921): call_user_func((Array:2), Object(DB_Error))
#2 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB.php(985): PEAR_Error->__construct("DB Error: no such field", -19, 16, (Array:2), "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#3 /var/www/html/sites/all/modules/contrib/civicrm/packages/PEAR.php(575): DB_Error->__construct(-19, 16, (Array:2), "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#4 [internal function](): PEAR->_raiseError(Object(DB_mysqli), NULL, -19, NULL, NULL, "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", "DB_Error", TRUE)
#5 /var/www/html/sites/all/modules/contrib/civicrm/packages/PEAR.php(224): call_user_func_array((Array:2), (Array:8))
#6 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/common.php(1905): PEAR->__call("raiseError", (Array:7))
#7 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/common.php(1905): PEAR->raiseError(NULL, -19, NULL, NULL, "CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", "DB_Error", TRUE)
#8 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/mysqli.php(933): DB_common->raiseError(-19, NULL, NULL, NULL, "1054 ** Unknown column 'is_minimized' in 'NEW'")
#9 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/mysqli.php(403): DB_mysqli->mysqliRaiseError()
#10 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/common.php(1216): DB_mysqli->simpleQuery("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#11 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/DataObject.php(2438): DB_common->query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#12 /var/www/html/sites/all/modules/contrib/civicrm/packages/DB/DataObject.php(1627): DB_DataObject->_query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#13 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/DAO.php(354): DB_DataObject->query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#14 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/DAO.php(1297): CRM_Core_DAO->query("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", FALSE)
#15 /var/www/html/sites/all/modules/contrib/civicrm/Civi/Core/SqlTriggers.php(225): CRM_Core_DAO::executeQuery("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...", (Array:0), TRUE, NULL, FALSE, FALSE)
#16 /var/www/html/sites/all/modules/contrib/civicrm/Civi/Core/SqlTriggers.php(171): Civi\Core\SqlTriggers->enqueueQuery("CREATE TRIGGER civicrm_dashboard_contact_after_insert after insert ON civicrm...")
#17 /var/www/html/sites/all/modules/contrib/civicrm/Civi/Core/SqlTriggers.php(70): Civi\Core\SqlTriggers->createTriggers((Array:486), NULL)
#18 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/DAO.php(1975): Civi\Core\SqlTriggers->rebuild(NULL, FALSE)
#19 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/I18n/Schema.php(352): CRM_Core_DAO::triggerRebuild()
#20 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/BAO/SchemaHandler.php(389): CRM_Core_I18n_Schema::rebuildMultilingualSchema((Array:3), NULL)
#21 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Upgrade/Incremental/php/FourSeven.php(829): CRM_Core_BAO_SchemaHandler::dropColumn("civicrm_dashboard_contact", "is_minimized")
#22 [internal function](): CRM_Upgrade_Incremental_php_FourSeven::dashboardSchemaUpdate(Object(CRM_Queue_TaskContext))
#23 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Task.php(88): call_user_func_array((Array:2), (Array:1))
#24 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Runner.php(214): CRM_Queue_Task->run(Object(CRM_Queue_TaskContext))
#25 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Page/AJAX.php(52): CRM_Queue_Runner->runNext(TRUE)
#26 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/ErrorPolicy.php(106): CRM_Queue_Page_AJAX::{closure}()
#27 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Queue/Page/AJAX.php(54): CRM_Queue_ErrorPolicy->call(Object(Closure))
#28 [internal function](): CRM_Queue_Page_AJAX::runNext()
#29 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Invoke.php(276): call_user_func((Array:2))
#30 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Invoke.php(84): CRM_Core_Invoke::runItem((Array:13))
#31 /var/www/html/sites/all/modules/contrib/civicrm/CRM/Core/Invoke.php(52): CRM_Core_Invoke::_invoke((Array:5))
#32 /var/www/html/sites/all/modules/contrib/civicrm/drupal/civicrm.module(448): CRM_Core_Invoke::invoke((Array:5))
#33 [internal function](): civicrm_invoke("upgrade", "queue", "ajax", "runNext")
#34 /var/www/html/includes/menu.inc(527): call_user_func_array("civicrm_invoke", (Array:4))
#35 /var/www/html/index.php(21): menu_execute_active_handler()
#36 {main}
  • Can you check your most recent log in sites/defaut/files/civicrm/ConfigAndLog and see what the last task was that it was running before it tripped this error? This is Drupal, right? – Christia Dec 23 '16 at 5:31
  • Thanks for getting back to me. Yes, it's a Drupal 7 website. I've posted the error log above. – wrender Dec 24 '16 at 15:00
  • I think I may have figured out the issue. It seems like on this website Logging is enabled in CiviCRM. When I disable logging before doing the update the CiviCRM update process completes properly. Going to do it a few more times to confirm. – wrender Dec 24 '16 at 15:38
  • Unfortunately, I'm having the same problem, but logging isn't enabled on my installation so that fix doesn't work for me. – Ken Williams Dec 25 '16 at 5:08
  • Ken, what does your sites/defaut/files/civicrm/ConfigAndLog show? – wrender Dec 28 '16 at 15:35
1

I can confirm. I had to disable the logging setting in CiviCRM before applying any updates. This seems to have resolved the upgrade process for me.

To disable logging go to the settings area in the admin section of CiviCRM.

| improve this answer | |
  • Can you edit your answer to describe how to disable logging in case anyone else needs to know? – Christia Dec 27 '16 at 9:08

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.