[Users] Presence server with MySQL >=5.0.26

Nicolas Palix nicolas.palix at labri.fr
Thu Nov 16 15:24:28 CET 2006


You're right... My database uses utf8.

Note that some default openser tables are also concerned.

Thanks for your answers.

Regards

Le jeudi 16 novembre 2006 15:09, Norman Brandinger a écrit :
> Perhaps the problem is related to the fact that UTF-8 uses 3-bytes to
> save a character.
> This issue was discussed at: http://bugs.mysql.com/bug.php?id=4541
>
> If the datbase encoding is UTF-8, then this will be important to you.
>
> Regards,
> Norm
>
> Watkins, Bradley wrote:
> > I originally sent this to the OP instead of the list by mistake:
> >
> > This sounds like a bug in the package you're using or MySQL 5.0.26
> > itself.  The storage requirements for the key should be 388 bytes, which
> > is much less (obviously) than the maximum key length of a MyISAM table.
> >
> > Empirically, I tested this on MySQL 5.0.22 (Fedora RPMs) and MySQL
> > 5.1.11 (RPMs from MySQL's website) with the original values and they
> > both worked.  The documentation for 5.0 and 5.1 on MySQL's site both
> > state the 1000 byte limitation (that is, without code modification).
> >
> >
> > As an additional data point not in the original e-mail above, using the
> > 5.0.27 .tar.gz from MySQL also has no problems with this table
> > definition.
> >
> > I've even gone so far as doubling the size of the fields used for the
> > PK, and none of the aforementioned versions balked.
> >
> > With the original sizes, it should even work in older (I think pre
> > 4.1.12?) versions of MySQL where the max key length is 500 bytes.  I
> > really don't think there's a problem here.
> >
> > Regards,
> > - Brad
> >
> >> -----Original Message-----
> >> From: users-bounces at openser.org
> >> [mailto:users-bounces at openser.org] On Behalf Of Bogdan-Andrei Iancu
> >> Sent: Thursday, November 16, 2006 7:06 AM
> >> To: Nicolas Palix; Anca Vamanu
> >> Cc: users at openser.org
> >> Subject: Re: [Users] Presence server with MySQL >=5.0.26
> >>
> >> Hi Nicolas,
> >>
> >> I think the solution will be to have a primary key a simple
> >> unsigned int outincrement field in the table and move the
> >> primary key as unique.
> >>
> >> I will ask Anca to do this change as most probably it will be
> >> a good idea to do it for the rest of the tables also.
> >>
> >> regards,
> >> Bogdan
> >>
> >> Nicolas Palix wrote:
> >>> Hi,
> >>>
> >>>
> >>> The primary key of the watchers is too long with this
> >>
> >> version of MySQL:
> >>> "Specified key was too long; max key length is 1000 bytes"
> >>>
> >>> Downgrading "[pw]_domain" from 128 to 96. Works.
> >>>
> >>> CREATE TABLE `watchers` (
> >>> `p_user` varchar(64) NOT NULL,
> >>> `p_domain` varchar(96) NOT NULL,
> >>> `w_user` varchar(64) NOT NULL,
> >>> `w_domain` varchar(96) NOT NULL,
> >>> `subs_status` varchar(64) NOT NULL,
> >>> `reason` varchar(64) NOT NULL,
> >>>  PRIMARY KEY  (`p_user`,`p_domain`,`w_user`,`w_domain`)
> >>> ) ENGINE=MyISAM;
> >>>
> >>> Regards
> >>
> >> _______________________________________________
> >> Users mailing list
> >> Users at openser.org
> >> http://openser.org/cgi-bin/mailman/listinfo/users
> >
> > The contents of this e-mail are intended for the named addressee only. It
> > contains information that may be confidential. Unless you are the named
> > addressee or an authorized designee, you may not copy or use it, or
> > disclose it to anyone else. If you received it in error please notify us
> > immediately and then destroy it.
> >
> > _______________________________________________
> > Users mailing list
> > Users at openser.org
> > http://openser.org/cgi-bin/mailman/listinfo/users
>
> _______________________________________________
> Users mailing list
> Users at openser.org
> http://openser.org/cgi-bin/mailman/listinfo/users

-- 
Nicolas Palix
http://phoenix.labri.fr/people/palix/




More information about the Users mailing list