Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Order By on a String
Message
From
17/09/2003 10:36:38
 
 
To
17/09/2003 10:23:29
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00829868
Message ID:
00829885
Views:
19
>I need to find badge numbers in order. I do select... Order on badgeno. The badgeno is a charactor, 'CNT1','CNT2','CNT3',...'CNT20'. It sorts as CNT1,CNT10,CNT2,CNT20. How can I get this in a numerical order?

Steven,

The badgno is not very well formatted for that

If the form of the badgeno is the same everywhere
select  left(badgeno,3), ;
        val(substr(Badgeno,4)), ;
        * ;
   from TheTable ;
   into cursor TheCursor ;
 order by 1,2
Gregory
Previous
Reply
Map
View

Click here to load this message in the networking platform