A few scrip questions

I’ve written an rt-crontool query that will find stalled tickets with a
"Starts" date of today, and open them (so we can take a work order that
doesn’t need to be touched for a while and have it in the system, but
out of view until it’s needed). I want to write a scrip that will
notify the ticket owner when such a stalled ticket is opened by the
rt-crontool query, and I’m having a bit of trouble.
Does anyone know how to either:

  1. make use of an external Perl module (Time::ParseDate) within a scrip
    custom condition
    or
  2. get the LastUpdatedBy attribute in a scrip

I ran up against a brick wall with the first, and thought I’d be clever
by using the second, only to find I couldn’t figure that one out either.

Thanks!

Here’s my rt-crontool query in case anyone is interested:
./rt-crontool --search RT::Search::FromSQL --search-arg "Status =
‘stalled’ AND Starts < ‘tomorrow’ AND Starts > ‘NULL’ " --action
RT::Action::SetStatus --action-arg “open”

Rather than just search for entries that start “today”, I wanted to
capture conditions in which the cron job may have been missed on a day
(outage) or if someone accidentally entered something with a year of
1970, hence the search for entries that are earlier than tomorrow. The
check to make sure it’s newer than null came after I accidentally opened
all our stalled tickets that had no “Starts” date in the ticket.

On Fri, 14 May 2010 16:21:10 -0700, “Nick Kartsioukas”
change+lists.rt@nightwind.net said:

I’ve written an rt-crontool query that will find stalled tickets with a
“Starts” date of today, and open them (so we can take a work order that
doesn’t need to be touched for a while and have it in the system, but
out of view until it’s needed). I want to write a scrip that will
notify the ticket owner when such a stalled ticket is opened by the
rt-crontool query, and I’m having a bit of trouble.

Fixed this by just having rt-crontool leave a comment on the ticket when
it opens it instead of using a scrip to do it, command now looks like
this:
rt-crontool --search RT::Search::FromSQL --search-arg "Status =
‘stalled’ AND Starts < ‘tomorrow’ AND Starts > ‘NULL’ " --action
RT::Action::RecordComment --template ‘Started Ticket’ --action
RT::Action::SetStatus --action-arg “open”