|
Posted by Bill on 02/01/08 23:27
Hi
PHP5.1.6 Zend 2.1.0 MySQL5.0.2 on Ubuntu 6.10
Values('10 x 12','8 x 10', '14 x 20','4 x 6') are stored in a varchar column
(size).
'select distinctrow * from table order by size' retrieves the sizes in
$slist but ordered as we know.
I want the rows to be ordered like '4 x 6, 8 x 10, 10 x 12, 14 x 20' so I
sorted it with:
$srtlst = natcasesort($slist)
but it outputs no result in $srtlst. Why ? is it a bug ?
How can I have the list sorted in natural order ?
Navigation:
[Reply to this message]
|