Alphanumeric Sorting

G

Guest

I have a Text field that contains apartment numbers that vary from 1a-25l.

How can I sort so that the numeric floors are in sequence, ie 1A--9L, 10A,
11,A rather than the text sort I receive of 10A,...10L, 1A, 1B,...

Any ideas
 
K

Ken Snell [MVP]

Sort using two fields:

SortField1: Val([FieldName])
SortField2: [FieldName]
 
R

Rick Brandt

John R said:
I have a Text field that contains apartment numbers that vary from 1a-25l.

How can I sort so that the numeric floors are in sequence, ie 1A--9L, 10A,
11,A rather than the text sort I receive of 10A,...10L, 1A, 1B,...

Any ideas

Sort on the expression...

Val([YourField])
 
G

Guest

Thanks Ken:

It worked well. The key was adding the second sort field.

Thanks again

Ken Snell said:
Sort using two fields:

SortField1: Val([FieldName])
SortField2: [FieldName]
--

Ken Snell
<MS ACCESS MVP>

John R said:
I have a Text field that contains apartment numbers that vary from 1a-25l.

How can I sort so that the numeric floors are in sequence, ie 1A--9L, 10A,
11,A rather than the text sort I receive of 10A,...10L, 1A, 1B,...

Any ideas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top