On Sat, 3 Jul 2004 02:37:55 -0400
Behdad Esfahbod [EMAIL PROTECTED] wrote:
On Sat, 3 Jul 2004, Ehsan Akhgari wrote:
For proper sorting using Glibc, it's not enough that the
application use Glibc, but it should call the sorting
function of Glibc too! (which apparently MySql does not).
Right.
I'd like to spend some time trying to patch MySQL sources to use glibc
collation functions before I give up and sort the data at the client
side. Would you mind letting me know which version of glibc I should be
using? Also, is there any resource/documentation/how-to available which
can guide me in this job?
It's not any easy to do what you are saying here, unless you make
sure you ALWAYS run your mysql under the same (fa_IR) locale, and
that the locale data does not change. Any Glibc version = 2.2
should be Ok.
Thanks everyone for the feedback so far. It's a kind of relief to hear that
we aren't the only people who've hit this issue.
Ehsan - are you thinking about adding glibc collation to the
strings/ctype-MYSET.c file? Or something more fundemental?
I think you and the team I'm working with are trying to do the same thing -
it would be great if we could work together and come up with a solution
that anyone else can use too.
What's involved in creating a collation file? These two pages:
http://dev.mysql.com/doc/mysql/en/Adding_character_set.html
http://dev.mysql.com/doc/mysql/en/Character_arrays.html
http://dev.mysql.com/doc/mysql/en/String_collating.html
seem to say that's it's not too difficult, if you know what you're doing?
(Which I dont. I'm just a humble PHP programmer)
... it seems it would be great to create a mySql Persian collation file
rather than changing the source, with all the problems that would lead to
of having to re-patch the code everytime there's a new MySql release? Or is
that inevitable?
Thanks again!
Peter
--
Peter Cruickshank
peterc at openconcept.ca
___
PersianComputing mailing list
[EMAIL PROTECTED]
http://lists.sharif.edu/mailman/listinfo/persiancomputing