Group Sorting

lewando_bria

BoRiS
Local time
Today, 00:56
Joined
Jun 18, 2002
Messages
29
hi there... i am formulating a report that needs to sorted based on each record's "Status"... the status can be either "R", "Y", or "G"...i have "Status" as a grouping category, but the problem is that I need it to go R, Y, then G...which is not in any alphabetical order...is there a way with code or otherwise to accomplish this...any help would be great!!!!!

thanks,

BoRiS
 
I know that this might not be what you want to here...but have you thought about assigning a numeric value to R, Y, and G!

I had to do that once. The user would select...and see Red, Amber, and Green, but I actually reported numbers. The reports would display values, but sort on numbers!

Or it could be a separate field...called...indicator. You could just say
If (Me.Status = R) Then
Me.indicator = 1
Else
If (Me.Status = Y) Then
Me.indicator = 2
Else
Me.indicator = 3
End If
End If

(Modification would have to be made if you allowed the field to contain a null value)


Just an idea.;)
 
Thanks for the help but I ended up putting an additional field in my query to look like this:

SortOrder: IIf([Release_Status]="R",1,IIf([Release_Status]="Y",2,3))

and set SortOrder as my grouping field with the [Status] field contained in it....Thanks for all the help!!!
 

Users who are viewing this thread

Back
Top Bottom