#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2000
    Posts
    4
    Rep Power
    0
    i'm new to mysql and php. when i sort a set of results by say "filesize" it returns something like this:
    119
    125
    26
    231
    this is obviously not what i want, but it is sorting alphabetically, instead of the whole integer. anyone know a way around this?
  2. #2
  3. No Profile Picture
    Apprentice Deity
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Jul 1999
    Location
    Niagara Falls (On the wrong side of the gorge)
    Posts
    3,237
    Rep Power
    19
    What is the data type for the column? If it isn't numeric (i.e. it IS char, varchar, text, blob, etc) then it will sort alphabetically. If it IS a numeric data type than it will sort numerically.

Similar Threads

  1. Dataview sorting integers
    By mia in forum .Net Development
    Replies: 0
    Last Post: February 5th, 2004, 11:24 AM
  2. casesensitive sorting in - apply templates
    By nihaarika2002 in forum XML Programming
    Replies: 2
    Last Post: January 15th, 2004, 03:06 AM
  3. Explanation of sorting in english, please
    By NelsonN in forum Perl Programming
    Replies: 4
    Last Post: November 2nd, 2003, 02:51 PM
  4. scanning a char buffer for integers
    By kavi_s in forum C Programming
    Replies: 2
    Last Post: June 9th, 2003, 11:06 AM
  5. Sorting an Multidimentional Array by multiple fields
    By pretender in forum PHP Development
    Replies: 5
    Last Post: January 18th, 2003, 02:48 AM

IMN logo majestic logo threadwatch logo seochat tools logo