Results 1 to 4 of 4

Thread: Sorting Text

  1. #1
    Join Date
    Aug 2004
    Location
    NY
    Posts
    113

    Unanswered: Sorting Text

    I have a question that I know (from searching) gets asked alot. I realize that if I want to sort numbers in text, I probably have to put a leading 0.
    If I were to change these numbers to number is it possible so that I can always get this format?
    Code:
    1.100
    10.250
    2.500
    this is what my numbers look like. Am I able to get these numbers 3 digits in Number format. I tried but I either lose the trailing numbers or it just always has it formatted 1.000, 10.000, 2.000.

    Thanks
    ======================
    Levent
    Access 3

  2. #2
    Join Date
    Aug 2004
    Location
    NY
    Posts
    113
    I just changed to currency with the #.### format and it looks like it is working.
    ======================
    Levent
    Access 3

  3. #3
    Join Date
    Jan 2007
    Location
    California, USA
    Posts
    520
    When I have numbers that are text, and I need to sort them as numbers, I create, in a query, another field where I put the Val(mynumber) and then sort on this new field, but continue to work with the text numbers.

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    if you are using exisitng data then someitmes you can recreate the numeric order by converting the string representation using an appropriate conversion function such as cint(<mydata>).

    buyt the real solution as you have already identified us to write the nuimbers properly in the first place, whether you use leading zeros or spaces is irrelevant. Most humans prefer leading spaces
    I'd rather be riding on the Tiger 800 or the Norton

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •