Bug at uptdating from version 0.8 to 0.9

Found a bug? Tell us!!
Post Reply
Viperb0y

Bug at uptdating from version 0.8 to 0.9

Post by Viperb0y »

Hi,

after I finished the upgrade process to 0.9 I get this error message:
CREATE INDEX plcomb_idx ON serendipity_permalinks (permalink, type);
/ Specified key was too long; max key length is 1000 bytes
CREATE INDEX plugincat_idx ON serendipity_plugincategories(class_name,
category);
/ Specified key was too long; max key length is 1000 bytes
I think this isn't very important, but maybe you can make a fix for this!

I use MySQL Version 5.0.15 and PHP Version 5.0.5
wesley
Regular
Posts: 197
Joined: Sun Jul 10, 2005 11:15 am
Contact:

Post by wesley »

Just a note: I have MySQL 5.0.15 and PHP 5.0.5 as well and didn't see that
error popping up.
I make s9y plugins, too.
My s9y blog depends on them. :)
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hm, that's strange. permlink is a varchar(255) and type a varchar(200). So they only add up to 455 bytes, which is less than 1000. Seems to be a MySQL5 oddity, I've just asked Isotopp and see if he can find the cause :)

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
takamori

index creation errors - me too

Post by takamori »

Hi,

I'm seeing the same errors while testing the upgrade from 0.8 to 0.9 on my test server. I have MySQL 4.1.14-nt and PHP 4.3.11. I am using utf8 as my default charset. Under the MySQL admin I see that the serendipity_permalinks table uses utf8_general_ci for the "collation method", and InnoDB is being used. Under the advanced tab for the table, Pack keys is set to default. The same values are set for serendipity_plugincategories as well.

I don't have much control over the live server's DB version/settings (aside from changing webhost providers), so if it's possible to fix it in code, that would be much preferred...

Btw at first glance, these errors don't seem to prevent me from using Serendipity 0.9 (being indices, rather than actual schema), but should I hold off from using 0.9 until this is resolved?
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: index creation errors - me too

Post by garvinhicking »

I think you can use the current version without problems, the index keys are not THAT important.

MySQL5 uses 4-byte index key storage for UTF-8 charsets instead of only 2-byte. Thus, an index which would take 400 bytes now takes up 4*400 bytes in the key creation. We will need to fix that by restricting the key length in the future.

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply