Custom sort order

K

Klatuu

FSKT

You could create a calculated field in your query than translates the field
into a ranking number and sort on that:

SortBy: =Switch([Fld] = "F", 1, [Fld] = "S", 2, [Fld] = "K", 3, [Fld] = "T",
4)
 
B

Billy Rogers

Fantastic!

Thanks a million.
--
Billy Rogers

Dallas,TX

Currently Using SQL Server 2000, Office 2000 and Office 2003

http://thedataguru.blogspot.com/


Klatuu said:
FSKT

You could create a calculated field in your query than translates the field
into a ranking number and sort on that:

SortBy: =Switch([Fld] = "F", 1, [Fld] = "S", 2, [Fld] = "K", 3, [Fld] = "T",
4)
--
Dave Hargis, Microsoft Access MVP


Billy Rogers said:
I have a query that returns rows like this

F
K
S
T

Is there a way to sort the rows to look like this?
F
S
K
T


--
Billy Rogers

Dallas,TX

Currently Using SQL Server 2000, Office 2000 and Office 2003

http://thedataguru.blogspot.com/
 

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

Top