[Rt-devel] Sorting an RT collection
Stephen Turner
sturner at MIT.EDU
Thu Apr 27 09:29:26 EDT 2006
Hello,
I have a need to sort a collection (of tickets) based on some
criterion that is not a simple table attribute/column. I'm thinking I
can populate a Tickets object in the normal way and then call a new
method to sort the internal array that holds the retrieved database rows.
Where I'm getting confused is: SearchBuilder maintains rows in an
array $self->{'items'}, but Tickets_Overlay seems to maintain a
second array $self->{'items_array'} (in the ItemsArrayRef method).
My questions are:
- Why two arrays?
- Can my goal be achieved as simply as I think (by sorting the
appropriate arrays) or is there more to it?
- Is this (sorting by not-a-table-column) done anywhere currently within RT?
Thanks,
Steve
Stephen Turner
Senior Programmer/Analyst - Client Support Services
MIT Information Services and Technology (IS&T)
More information about the Rt-devel
mailing list