[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: ORDER BY



If you are using Oracle you can use the DECODE() function.

-----Original Message-----
From: Chuck Harkness [mailto:c.a.harkness@LARC.NASA.GOV]
Sent: Wednesday, March 14, 2001 5:18 PM
To: SQR-USERS@list.iex.net
Subject: ORDER BY


Hello!
  I am trying to use an order by clause on a char field, but the order
doesn't come out quite like the customer wanted.  For example, I have the
values: 1,1SL,1SM,1UP,100,197,198,199 and 1000.  The order by clause in SQR
produces the following order:

1
100
197
198
199
1SL
1SM
1UP
1000

I would like the order to be 1,1SL,1UP,100,197,198,199,100.  Does anyone
have any suggestions?

Thank you,
  Chuck