After Upgrade 2.2.5 to 2.3.0 Getting Error:CMS_BLOCK_STORE_BLOCK_ID_CMS_BLOCK_BLOCK_ID' to system tables,
-
08-02-2021 - |
Question
After Upgrade 2.2.5 To 2.3.0 when i am runnung php bin/magento setup:upgrade it give bellow error:
Schema creation/updates:
SQLSTATE[HY000]: General error: 1823 Failed to add the foreign key constraint 'test@test@002dtestnew/CMS_BLOCK_STORE_BLOCK_ID_CMS_BLOCK_BLOCK_ID' to system tables, query was: ALTER TABLE
cms_block_store
MODIFY COLUMNblock_id
smallint(6) NOT NULL , ADD CONSTRAINTCMS_BLOCK_STORE_BLOCK_ID_CMS_BLOCK_BLOCK_ID
FOREIGN KEY (block_id
) REFERENCEScms_block
(block_id
) ON DELETE CASCADE, ADD CONSTRAINTCMS_BLOCK_STORE_STORE_ID_STORE_STORE_ID
FOREIGN KEY (store_id
) REFERENCESstore
(store_id
) ON DELETE CASCADE
Solution
An error was due to Duplicate tables in a database, BK_cms_block. i was copied table and rename it for backup purpose and that creating issue , so i just delete BK tables and error resolve