php-5.3
Postgresql 8.3 and 9.1
Enabling the Fusion Apply module results in the following errors:
Notice: Array to string conversion in DatabaseSchema_pgsql->createTableSql() (line 131 of /home/graeme/html/includes/database/pgsql/schema.inc).
Notice: Array to string conversion in DatabaseSchema_pgsql->createTableSql() (line 131 of /home/graeme/html/includes/database/pgsql/schema.inc).
Notice: Array to string conversion in DatabaseSchema_pgsql->createTableSql() (line 131 of /home/graeme/html/includes/database/pgsql/schema.inc).
Notice: Array to string conversion in DatabaseSchema_pgsql->createTableSql() (line 131 of /home/graeme/html/includes/database/pgsql/schema.inc).
PDOException: SQLSTATE[42601]: Syntax error: 7 ERROR: syntax error at or near "Array" LINE 10: ...apply_skins_theme_module_element_skin_key UNIQUE (Array, Arr... ^: CREATE TABLE {fusion_apply_skins} ( sid serial CHECK (sid >= 0), theme varchar(128) NOT NULL default '', module varchar(128) NOT NULL default '', element varchar(128) NOT NULL default '', skin varchar(255) NOT NULL default '', options text NOT NULL, status smallint NOT NULL default 0, PRIMARY KEY (sid), CONSTRAINT fusion_apply_skins_theme_module_element_skin_key UNIQUE (Array, Array, Array, Array) ); Array ( ) in db_create_table() (line 2684 of /home/graeme/html/includes/database/database.inc).
Comments
Comment #1
pixelpreview@gmail.com commentedsame problem with mysql
PDOException : SQLSTATE[42000]: Syntax error or access violation: 1071
Comment #2
sheena_d commentedCan you try uninstalling the module, applying the patch at http://drupal.org/node/1325542#comment-5190902 and then re-installing to see if the issue persists?
Thanks!
Comment #3
esmerel commentedComment #4
sheena_d commentedActually, I just created a dev release, so you could just try that version instead of applying the patch I linked to.
Comment #5
murgatroid commentedStill not working. SQL log reveals the following
ERROR: syntax error at or near "Array" at character 381
STATEMENT: CREATE TABLE fusion_apply_skins (
sid serial CHECK (sid >= 0),
theme varchar(128) NOT NULL default '',
module varchar(128) NOT NULL default '',
element varchar(128) NOT NULL default '',
skin varchar(255) NOT NULL default '',
options text NOT NULL,
status smallint NOT NULL default 0,
PRIMARY KEY (sid),
CONSTRAINT fusion_apply_skins_theme_module_element_skin_key UNIQUE (Array, Array, Array, Array)
)
Can I ask why the constraint is contructed as unique keys with integer parameters? What's the funkiness which you are trying to achieve which I do not yet grok? (ok I'm guessing FILLFACTOR, but please, correct me if needed)
'unique keys' => array(
'theme_module_element_skin' => array(array('theme', 40), array('module', 40), array('element', 40), array('skin', 40)),
changing the array to
'theme_module_element_skin' => array('theme', 'module', 'element', 'skin'),
unbreaks the install. Is there another/better way to do this?
Comment #6
aquariumtap commentedFor a full history of why those integers were introduced, read over this issue: #1325542: fusion_apply_skins table - "Specified key was too long; max key length is 1000 bytes". Their purpose is to abide by prefix limits in MySQL indexes.
@murgatroid, are you using Postgresql as well? If not, which database system/version are you using?
Comment #7
murgatroid commentedAs per my initial post, I've tested it on 8.3 and 9.1. Also, the database has been sqeaky clean each time - drop db, drop site, re-install from scratch
Comment #8
sheena_d commentedI think aquariumtap meant to direct that database version question to @pixelpreview.
Comment #9
aquariumtap commentedMy apologies, I mistakenly thought somebody other than @murgatroid had written the original post. But yes, @pixelpreview, please let us know which version of MySQL you are using.
If PostgreSQL doesn't support prefix limits, then DBTNG needs to reflect that. This should be written up as a bug in core.