fix(installer): drop legacy remote columns in PHP, not PREPARE-based SQL #218
Reference in New Issue
Block a user
Delete Branch "fix/sql-prepared-statement-protocol"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Targeting dev for a dev pre-release / suite.dev testing before it reaches stable.
Bug
Updating the component on MySQL 8 aborts with:
Cause
sql/updates/mysql/02.56.01.sqlpurges the 26 legacy remote columns portably by building a conditionalALTERand running it withPREPARE/EXECUTE/DEALLOCATE. Those statements are rejected by Joomla's installer SQL path on MySQL 8 (error 1295), so replaying the file (e.g. from an old stuck schema) aborts the entire component install.Fix
02.56.01.sql→ no-op comment (removes the PREPARE block).Pkg_MokoSuiteBackupInstallerScript::dropLegacyRemoteColumns()now does the purge in PHP: gate onINFORMATION_SCHEMA, then one plainALTER TABLE … DROP COLUMN …for only the columns that still exist — portable across MariaDB and MySQL 8, idempotent, non-fatal.php -lclean. dev was just re-synced to main (02.57.00 + all session fixes), so this dev build = 02.57.00 + this fix.https://claude.ai/code/session_01WbGBN9VyRK61zczYWcCQ2i