Of course, I wouldn't want appropriate 0's stripped...

10:001-005
10:014-018
10:006-008

If those were the values, the first 0's for 10: would need to stay...

Rick

  -----Original Message-----
  From: Rick Faircloth [mailto:[EMAIL PROTECTED]
  Sent: Thursday, May 20, 2004 2:50 PM
  To: CF-Talk
  Subject: RE: How can I order these values numerically?

  What would be the code if I inserted the values as

  1:001-005
  1:014-018
  1:006-008

  so that they would sort correctly as entered,
  then strip out all 0's for display?

  Rick

    -----Original Message-----
    From: Ben Doom [mailto:[EMAIL PROTECTED]
    Sent: Thursday, May 20, 2004 1:47 PM
    To: CF-Talk
    Subject: Re: How can I order these values numerically?

    Order by the length of the field, then the field itself.  This won't
    always work if there are overlaps.

    --Ben Doom

    Rick Faircloth wrote:

    > Hi, all...
    >
    > How can I order these values numerically?
    >
    > 1:1-5
    > 1:14-18
    > 1:6-8
    >
    > How can I, without making the db field a numeric field rather than a
  varchar
    > field,
    > cause these values to be ordered this way:
    >
    > 1:1-5
    > 1:6-8
    > 1:14-18
    >
    > Thanks for your help...
    >
    > Rick
    >
    > --
    > Outgoing mail is certified Virus Free.
    > Checked by AVG Anti-Virus (http://www.grisoft.com).
    > Version: 7.0.241 / Virus Database: 262.10.2 - Release Date: 5/18/2004
    >
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to