User variables and cleanup script

I’m just getting started with RT, and was looking at modifying the
"Quick Search" to show users instead of queue’s. Looks like I’d have to
modify:

while (my $queue = $Queues->Next) {
and
$Tickets->LimitQueue(VALUE => $queue->Name, OPERATOR => ‘=’);

But not sure where to find the right variables/arrays for users and not
queue’s. Tried searching for it, but not really sure what I’m looking
for.

Does anyone have a script to just dump all the tickets but leave the
permissions and everything in place?

Thanks,
Dan