I am using the module on a clean install of 4.7 final. When I enable the module the database tables are not created via the .install script and, accordingly, I get all types of errors about certain tables not existing.
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | amazon_2.install | 6.12 KB | Prometheus6 |
Comments
Comment #1
Prometheus6 commentedDetails? Operating system, PHP version, database type?
Comment #2
bryansd commentedFor a fresh install...I don't even see the files amazon.mysql (MySQL) or amazon.pgsql (PostgreSQL). Are they missing or am I just looking in the wrong place?
Comment #3
eaton commentedUnder Drupal 4.7, the database installation is handled by the .install file.
Comment #4
Prometheus6 commentedI just did a clean install of 4.7 and enabled the module with no problem. From what you've given, that's all I can do.
Comment #5
Tiburón commentedHi,
I have trouble getting Amazontools to work under Drupal 4.7 too.
My host is using:
The version of the install script:
This is the error I got in Drupal when first activating the modul (I have only changed the installpath listed last):
Not that easy to read with no linefeeds, but notice the message "Specified key was too long; max key length is 1000 bytes". It will show it's head again below.
Checking the database with phpMyAdmin revealed that the table amazonitem was not created but amazonnode was.
I tried to run the SQL statement for creating the amazonitem table in phpMyAdmin but got the same result, same error message.
I removed the "DEFAULT CHARACTER SET utf8" bit and tried again. This time the table got created but was using latin1 not utf8.
I manually started to change the latin1 fields to utf8 one by one, and I managed to get all but one row changed:
I hope this info can help you find a solution...
Regards,
Christian Larsen
Comment #6
Prometheus6 commentedOkay, that did it.
The problem is an index. Now that we're all utf-8, a character can be more than one byte in size, so the author index is now bigger than MySQL will support. Since the index was just there "in case," I'm dropping it.
I'm attaching the new install file. Since you've already installed it once, there's a record in the system table that must go to get a fresh start.
delete from system where name='amazon'
Drop the old tables and you should be okay.
Comment #7
Prometheus6 commentedComment #8
Tiburón commentedGreat,
I cleaned the database, replaced the amazon.install file, went to the modules page and activated amazontools.
No errors this time :-)
I have checked the database, and the tables are listed as utf8 encoded.
Thank you for the quick response, and the extra info about the cause of the problem.
Regards,
Christian Larsen
Comment #9
bryansd commentedAlso thanks to Tiburon for posting the details to the problem. I was a little too busy to throw anything more than simple "me too".
-Bryan
Comment #10
Prometheus6 commentedAgreed. With that level of detail not only was it quick to find, I felt I had no choice! ;-)
Comment #11
Prometheus6 commentedComment #12
greg.harveyGood explanation here, for anyone chasing a similar issue:
http://www.calivia.com/blog/mike/mysql-innodb-specified-key-was-too-long...