Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sort combo box (lookup field)

Status
Not open for further replies.

KellyJo

Technical User
Sep 14, 2004
24
US
have a lookup field for my table that pulls its data from Pay period table

When I click the drop down in my table, the dates aren't in any order. I think this is because lookup fields are considered text fields.

Is there a way to sort my drop down box on the table?

KellyJo
 
There are various ways.

Date fields are actual date fields which are sorted by date. However, if your pay periods are actually the names of say, months, then April is going to showup first infront of August, etc.

There are several approaches. Some are pretty niffty. but perhaps the simplest is to add a field to your pay periods - perhaps year + month - this can be a done as a text or numeric. 200401, 200402, etc. Make sure you keep the leading zero in front of month and/or week. You can sort by this number / text, and display the pay period you wish to display.

Richard
 
Thank you so much. That was such a great idea. Sometimes when you've been looking at a database for a few weeks, it takes an outside voice to help you think things through. Thanks again!

KellyJo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top