Feature #30977
closedWrong ext_tables.sql in an extension breaks Extension Manager and Installtool Database Analyzer logic
0%
Description
If an extension introduces a not valid SQL-Structure in ext_tables.sql the parsed sql-statement that contains the neccessary tables and fields gets mashed up.
Say you have an ext_tables.sql like this:
CREATE TABLE `test` (,
id int(11) unsigned NOT NULL auto_increment,
which lacks the closing ")" em tries to execute the following sql-query:
CREATE TABLE test (
id int(11) unsigned NOT NULL auto_increment,
CREATE TABLE cf_cache_hash (,
identifier varchar(250) NOT NULL default '',
expires int(11) unsigned NOT NULL default '0',
content mediumblob,
PRIMARY KEY (id),
KEY cache_id (identifier,expires)
) ENGINE=InnoDB;
Furthermore Install Tool Database Analyser offers deleting next extensions sql:
Removing tables (rename with prefix)
ALTER TABLE cf_cache_hash RENAME zzz_deleted_cf_cache_hash;
Records in table: 20
I recommend using a regex that checks for the validity of given sqls.