Alphanumeric Sort Order

Tophan

Registered User.
Local time
Today, 01:09
Joined
Mar 27, 2011
Messages
374
Hello,

I have a field in my database which consists of an alpha-numeric code. These codes are not created internally but are provided by external resources and as such I cannot change them. The problem I am getting is the sorting of records in reports, combo boxes, etc.

For example, the first sequence in the field is A-S0 to A-S13. However, in the report the records are listed as follows

A-S0
A-S1
A-S10
A-S11
A-S12
A-S13
A-S2
A-S3 and so on up to A-S9.

Is there any way I can have these records sorted in the correct order with A-S10 to A-S13 listing after A-S9?
 
Sort on Left(yourfield,3) and on Cint(right(yourfield,2)

Correction:

Left(yourfield,3) and Cint(Mid(yourfield,4))
 
Thanks but I'm still a novice. I understand the argument but where/how would I key this in?
 
Google

Sorting access forms
sorting access queries
 

Users who are viewing this thread

Back
Top Bottom