Body: <p>Updating CiviCRM to 5.78.1 and was at the database update. It appeared it was about to finish when I got a Core Exception telling me that it couldn't create table civicrm_search_display since it already exists.  Which is does - I verified via Show Tables.
  Full error is here:</p>
  <pre><code>CRM_Core_Exception: Cannot execute CREATE TABLE `civicrm_search_display` ( `id` int unsigned NOT NULL AUTO_INCREMENT COMMENT 'Unique SearchDisplay ID', `name` varchar(255) NOT NULL COMMENT 'Unique name for identifying search display', `label` varchar(255) NOT NULL COMMENT 'Label for identifying search display to administrators', `saved_search_id` int unsigned NOT NULL COMMENT 'FK to saved search table.', `type` varchar(128) NOT NULL COMMENT 'Type of display', `settings` text DEFAULT NULL COMMENT 'Configuration data for the search display', `acl_bypass` boolean DEFAULT FALSE COMMENT 'Skip permission checks and ACLs when running this display.', PRIMARY KEY (`id`), UNIQUE INDEX `UI_saved_search__id_name`(`saved_search_id`, `name`) ) ENGINE=InnoDB DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ROW_FORMAT=DYNAMIC: DB Error: already exists in /var/www/html/wp-content/plugins/civicrm/civicrm/mixin/lib/civimix-schema/src/SchemaHelper.php on line 66
  </code></pre>
  <p>Any ideas on this?  It was sooooo close!
  Thanks!</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-10-17T09:15:56.653Z
Comments.Text: Possible workaround: backup the table, remove it from the db, re-run upgrade, restore the table data from the backup.
Comments.UserDisplayName: yurg
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-10-17T11:34:21.073Z
Comments.Text: What version are you upgrading from?
Comments.UserDisplayName: Coleman
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-10-18T14:06:51.537Z
Comments.Text: Updating from old (2022) 5.48.?
  Wordpress is up to date at 6.6.2
  I did attempt again with an LTS version 5.75.2 and, while I didn't get that same error, it just never finished - update process was hung even after three hours.  Which basically just caused all extensions to fail.
  So I am waiting now until our donation folk can give me free reign again for a day and I will try disabling all extensions and removing the non-core ones and trying it again.
Comments.UserDisplayName: thomjones
Tags: <wordpress><upgrade>
Title: Error updating DB to 5.78.1 - and it almost finished!
ThreadText: # Error updating DB to 5.78.1 - and it almost finished!
  
  (Asked by: username_0 on 2024-10-16)
  
  Updating CiviCRM to 5.78.1 and was at the database update. It appeared it was about to finish when I got a Core Exception telling me that it couldn't create table civicrm_search_display since it already exists.  Which is does - I verified via Show Tables.
  Full error is here:
  CRM_Core_Exception: Cannot execute CREATE TABLE `civicrm_search_display` ( `id` int unsigned NOT NULL AUTO_INCREMENT COMMENT 'Unique SearchDisplay ID', `name` varchar(255) NOT NULL COMMENT 'Unique name for identifying search display', `label` varchar(255) NOT NULL COMMENT 'Label for identifying search display to administrators', `saved_search_id` int unsigned NOT NULL COMMENT 'FK to saved search table.', `type` varchar(128) NOT NULL COMMENT 'Type of display', `settings` text DEFAULT NULL COMMENT 'Configuration data for the search display', `acl_bypass` boolean DEFAULT FALSE COMMENT 'Skip permission checks and ACLs when running this display.', PRIMARY KEY (`id`), UNIQUE INDEX `UI_saved_search__id_name`(`saved_search_id`, `name`) ) ENGINE=InnoDB DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ROW_FORMAT=DYNAMIC: DB Error: already exists in /var/www/html/wp-content/plugins/civicrm/civicrm/mixin/lib/civimix-schema/src/SchemaHelper.php on line 66
  
  Any ideas on this?  It was sooooo close!
  Thanks!
  
  **Tags:** wordpress, upgrade
  
  > **Comments:**
  > **username_1**: Possible workaround: backup the table, remove it from the db, re-run upgrade, restore the table data from the backup.  
  > **username_2**: What version are you upgrading from?  
  > **username_0**: Updating from old (2022) 5.48.? Wordpress is up to date at 6.6.2 I did attempt again with an LTS version 5.75.2 and, while I didn't get that same error, it just never finished - update process was hung even after three hours.  Which basically just caused all extensions to fail. So I am waiting now until our donation folk can give me free reign again for a day and I will try disabling all extensions and removing the non-core ones and trying it again.  
  
  ---
  
  ## 0 answers
  
  