Update von 6.7.8.2 auf 6.7.12.1 - General error: 1553 Cannot drop index '': needed in a foreign key constraint"

Hallo,

PHP 8.4
MySQL 8.4

ich erhalte folgende Fehler-Meldung beim Update:

Run Post Update
Get collection for identifier: „core“
migrate Migrations
0/65 [░░░░░░░░░░░░░░░░░░░░░░░░░░░░] 0% < 1 ms/< 1 ms 167.0 MiB
1/65 [░░░░░░░░░░░░░░░░░░░░░░░░░░░░] 1% 2 s/2 min, 10 s 167.0 MiB07:57:47 ERROR [app] Migration: „Shopware\Core\Migration\V6_7\Migration1772007509ProductMainCategoryInheritance“ failed: „An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1553 Cannot drop index ‚‘: needed in a foreign key constraint“


Action Number of migrations


Migrated 6 out of 65


Was kann ich tun?
Danke

Roman

In der Datenbank den Parameter ‚restrict_fk_on_non_standard_key‘ auf Off bzw. 0 stellen.

Siehe dazu:

Hey,

hab mal ein issue erstellt. das ist ein echter bug: MySQL 8.4 upgrade to 6.7.12.1 fails in ProductMainCategoryInheritance migration with error 1553 · Issue #18582 · shopware/shopware · GitHub

Nur mal so als Nachtrag: Darüber sind auch schon einige Plugin-Hersteller (z.B. Pickware) gestolpert. In der Programmierung kann man das mit

SET SESSION restrict_fk_on_non_standard_key = 0;
SET SESSION foreign_key_checks = 0;
… neue Spalte einfügen ..
SET SESSION foreign_key_checks = 1;
SET SESSION restrict_fk_on_non_standard_key = 1;

umgehen.