Re: [PHP] Problem with sorting
Michelle Konzack schreef: * Do not Cc: me, because I READ THIS LIST, if I write here * *Keine Cc: am mich, ich LESE DIESE LISTE wenn ich hier schreibe* Hello, I have a Database of µChips and I want to sort it case insensitive and in numerical order in the same time. Since the name of the µChips are mostly [:alpha:][:num:]* I am running into problems since the first one can have 0-5 characters. So, what I need is to get the substring (leading [:alpha:]) unify and sort it and not use a loop over it, and get all chips from the category. Now from each category cut the [:alpha:], the sort numerical and after this re-add the cuted [:alpha:]. H, first I am searching a solution the get the Categories, which mean, the leading [:alpha:] AND, if numerical categories exist, there first number. The listing should be something like 3 8 AW AT DS ICL LM MAX W Does somone has a solution for it? (I do not like to reinvent the wheel) sounds like the best course of action is to normalize the various bits of data and insert/update them as seperate extra field(s?) whenever the source data (chip name) changes ... then use the percompiled/normalized data fields to perform simple per category searching/listing. Thanks, Greetings and nice Day/Evening Michelle Konzack Systemadministrator 24V Electronic Engineer Tamay Dogan Network Debian GNU/Linux Consultant -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Problem with sorting
* Do not Cc: me, because I READ THIS LIST, if I write here * *Keine Cc: am mich, ich LESE DIESE LISTE wenn ich hier schreibe* Hello, I have a Database of µChips and I want to sort it case insensitive and in numerical order in the same time. Since the name of the µChips are mostly [:alpha:][:num:]* I am running into problems since the first one can have 0-5 characters. So, what I need is to get the substring (leading [:alpha:]) unify and sort it and not use a loop over it, and get all chips from the category. Now from each category cut the [:alpha:], the sort numerical and after this re-add the cuted [:alpha:]. H, first I am searching a solution the get the Categories, which mean, the leading [:alpha:] AND, if numerical categories exist, there first number. The listing should be something like 3 8 AW AT DS ICL LM MAX W Does somone has a solution for it? (I do not like to reinvent the wheel) Thanks, Greetings and nice Day/Evening Michelle Konzack Systemadministrator 24V Electronic Engineer Tamay Dogan Network Debian GNU/Linux Consultant -- Linux-User #280138 with the Linux Counter, http://counter.li.org/ # Debian GNU/Linux Consultant # Michelle Konzack Apt. 917 ICQ #328449886 +49/177/935194750, rue de Soultz MSN LinuxMichi +33/6/61925193 67100 Strasbourg/France IRC #Debian (irc.icq.com) signature.pgp Description: Digital signature