[Rt-devel] Re: [rt-users] Sorting question

Andy Moran andy at wildbrain.com
Fri Nov 11 19:36:35 EST 2005


Okay I'm gonna try the rt-devel list on this one cause I can't figure it
out and it's become higher priority for me to do so.  I got a
suggestions on the rt-users list but couldn't get it to work.

I want to modify Elements/MyTickets to double sort -- first by id and
then by priority -- so that it's ultimately sorted in descending
priority order and within each priority ascending by ticket id.   As it
is now, the tickets Ids seem random within priority, and we don't change
priority much (Although we occasionally do).

Anybody know how to do this?


Thanks!

--Andy


Andrew Moran wrote:
> Jay and Ruslan,
> 
> Thanks for your input.      I ran into the same wall that you did, Jay 
> --  priority is ascending and within a priority, ticket ids are 
> descending.     Neither "DESC,ASC" or "DESC|ASC" seemed to help.   I 
> could change the ascending/descending order of the ticket ids, but 
> priorities were always ascending.
> 
> I'm not sure how to keep it descending by priority but ascending by 
> ticket.      hrmmm..
> 
> 
> --Andy
> 
> 
> Jay R. Ashworth wrote:
> 
> 
>>On Thu, Nov 03, 2005 at 11:14:15PM +0300, Ruslan Zakirov wrote:
>> 
>>
>>
>>>>The obvious solution (which I have not tested :-) would be to modify
>>>>
>>>>       OrderBy => 'Priority',
>>>>
>>>>to
>>>>
>>>>       OrderBy => 'Priority,Id',
>>>>     
>>>>
>>>
>>>AFAIK:
>>>OrderBy => 'Priority|id'
>>>Order => 'DESC|ASC'
>>>   
>>>
>>
>>Ok; I thought something like that might work, but I didn't go that far
>>into testing it.  Thanks.  The | instead of comma thing has to do with
>>the API in use there?
>>
>>Cheers,
>>-- jra
>> 
>>
> 
> 
> _______________________________________________
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
> 
> Be sure to check out the RT Wiki at http://wiki.bestpractical.com
> 
> Buy your copy of our new book, RT Essentials, today! 
> 
> Download a free sample chapter from http://rtbook.bestpractical.com
> 



More information about the Rt-devel mailing list