Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Aaron McCormack
Nevermind, I tried this in testing on 4.2 and it didn't fix it.  I was thinking 
perhaps the human readable parsing was changing how the date was considered, 
but it doesn't seem to be the case.

Aaron 
> On Dec 19, 2016, at 3:16 PM, Aaron McCormack  wrote:
> 
> Alex, could it be an accidental reversal of > and < ?
> 
> I think LastUpdated >= '3 days ago' is more of the intent because you were 
> surprised of seeing tickets which were updated within the past day.  
> 
> Aaron
> 
> 
>> On Dec 19, 2016, at 12:32 PM, Alex Hall > > wrote:
>> 
>> Well, I found something that works. It's not UntouchedInHours, but this 
>> query seems to return what I want:
>> 
>> select id
>> from Tickets
>> where LastUpdated <= (now() - INTERVAL 10 DAYS);
>> 
>> I still have to work out how to email ticket owners, but at least I can get 
>> the right tickets now. Odd that the other way doesn't work. How exactly does 
>> this "10 days ago" syntax get interpreted? Or is it no longer supported?
>> 
>> On Mon, Dec 19, 2016 at 2:48 PM, Alex Hall > > wrote:
>> I'm using the Crontool, yes, but I've also been doing searches on the web 
>> interface to see if I could get this to work. My Crontool syntax is 
>> something like:
>> 
>> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
>> --search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
>> --action RT::Action \
>> --verbose
>> 
>> Or:
>> 
>> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
>> --search-arg "status != 'resolved'" \
>> --condition RT::Condition::UntouchedInHours \
>> --arg-condition 72 \
>> --verbose
>> 
>> This shouldn't be modifying tickets, yet I'm seeing tickets created hours or 
>> minutes ago appearing in the results. Same for my RT web searches for 
>> similar SQL to what's above.
>> 
>> I'm in the database now, looking at the Tickets table and messing with 
>> queries. I just tried this, but got an empty set:
>> 
>> select id, LastUpdated
>> from Tickets
>> where LastUpdated <= '3 days ago'
>> order by LastUpdated DESC
>> limit 10;
>> 
>> I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is 
>> something RT interprets before giving the query to the database engine. 
>> Still, it was worth a shot. I'm now refreshing my knowledge of date math in 
>> MySQL so I can query exactly what I want, but I hoped UntouchedInHours would 
>> do all that for me. Oh, and yes, LastUpdated does seem to have normal values 
>> in it. They're in GMT time, but they seem to be correct.
>> 
>> On Mon, Dec 19, 2016 at 2:37 PM, Matt Zagrabelny > > wrote:
>> Hi Alex,
>> 
>> On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall > > wrote:
>> > Hello all,
>> > I'm trying to get stale ticket alerts working, so am using the
>> > UntouchedInHours condition. I've also tried, in SQL:
>> > LastUpdated <= '2 days ago'
>> > and similar searches. Yet, I always get the same number of tickets as I get
>> > when I leave the date restriction off completely, and UntouchedInHours is
>> > always giving me tickets opened today.
>> 
>> I assume you are using rtcrontool. Correct?
>> 
>> How are you alerting?
>> 
>> Is the alerting actually "touching" the tickets thus affecting the query?
>> 
>> You can query the tickets table directly and see the lastupdated
>> field. See if that field changes how you would expect when you "touch"
>> or "update" a ticket.
>> 
>> -m
>> 
>> 
>> 
>> -- 
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com 
>> 
>> 
>> 
>> -- 
>> Alex Hall
>> Automatic Distributors, IT department
>> ah...@autodist.com 
> 



Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Aaron McCormack
Alex, could it be an accidental reversal of > and < ?

I think LastUpdated >= '3 days ago' is more of the intent because you were 
surprised of seeing tickets which were updated within the past day.  

Aaron


> On Dec 19, 2016, at 12:32 PM, Alex Hall  wrote:
> 
> Well, I found something that works. It's not UntouchedInHours, but this query 
> seems to return what I want:
> 
> select id
> from Tickets
> where LastUpdated <= (now() - INTERVAL 10 DAYS);
> 
> I still have to work out how to email ticket owners, but at least I can get 
> the right tickets now. Odd that the other way doesn't work. How exactly does 
> this "10 days ago" syntax get interpreted? Or is it no longer supported?
> 
> On Mon, Dec 19, 2016 at 2:48 PM, Alex Hall  > wrote:
> I'm using the Crontool, yes, but I've also been doing searches on the web 
> interface to see if I could get this to work. My Crontool syntax is something 
> like:
> 
> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
> --search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
> --action RT::Action \
> --verbose
> 
> Or:
> 
> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
> --search-arg "status != 'resolved'" \
> --condition RT::Condition::UntouchedInHours \
> --arg-condition 72 \
> --verbose
> 
> This shouldn't be modifying tickets, yet I'm seeing tickets created hours or 
> minutes ago appearing in the results. Same for my RT web searches for similar 
> SQL to what's above.
> 
> I'm in the database now, looking at the Tickets table and messing with 
> queries. I just tried this, but got an empty set:
> 
> select id, LastUpdated
> from Tickets
> where LastUpdated <= '3 days ago'
> order by LastUpdated DESC
> limit 10;
> 
> I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is 
> something RT interprets before giving the query to the database engine. 
> Still, it was worth a shot. I'm now refreshing my knowledge of date math in 
> MySQL so I can query exactly what I want, but I hoped UntouchedInHours would 
> do all that for me. Oh, and yes, LastUpdated does seem to have normal values 
> in it. They're in GMT time, but they seem to be correct.
> 
> On Mon, Dec 19, 2016 at 2:37 PM, Matt Zagrabelny  > wrote:
> Hi Alex,
> 
> On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall  > wrote:
> > Hello all,
> > I'm trying to get stale ticket alerts working, so am using the
> > UntouchedInHours condition. I've also tried, in SQL:
> > LastUpdated <= '2 days ago'
> > and similar searches. Yet, I always get the same number of tickets as I get
> > when I leave the date restriction off completely, and UntouchedInHours is
> > always giving me tickets opened today.
> 
> I assume you are using rtcrontool. Correct?
> 
> How are you alerting?
> 
> Is the alerting actually "touching" the tickets thus affecting the query?
> 
> You can query the tickets table directly and see the lastupdated
> field. See if that field changes how you would expect when you "touch"
> or "update" a ticket.
> 
> -m
> 
> 
> 
> -- 
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com 
> 
> 
> 
> -- 
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com 



[rt-users] Emailing with NotifyOwnerOrAdminCc action?

2016-12-19 Thread Alex Hall
Hi all,
Now that I'm getting the tickets I want, I'm trying to email the owners of
those tickets. After my search and search-arg parameters for rt-crontool,
I'm doing this:

--action RT::Action::NotifyOwnerOrAdminCc \
--template "untouched ticket"

I'm missing --action-arg, but I don't know what to put for that since
NotifyOwnerOrAdminCc will, I presume, take care of it. However, I'm getting
an error:

can't call method "Message" on an undefined value at
/opt/rt4/bin/../lib/RT/Action/SendEmail.pm on line 1118

I'm assuming this is what I mentioned--my missing action-arg--but I don't
know what to put in there. Right now, the search is limited to just my own
tickets, but eventually it'll run with no owner restriction so it can
notify all users. Thus, the email address to use is whatever the owner's
address is, and I can't hard-code it. What's the trick to getting this to
work correctly? Thanks!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] external templates

2016-12-19 Thread Matt Zagrabelny
Hey Woody,

I haven't encountered external templates. Obviously, anything is
possible - but I don't know the best solution for your problem.

-m

On Mon, Dec 19, 2016 at 11:14 AM, Woody - Wild Thing Safaris
 wrote:
> Hi All,
>
> I've searched long and hard, but to my surprise not found anything that
> relates to external templates - maybe it's so trivially obvious that the
> question is a non question, but i have to ask it.
>
> i have externalised customfields, conditions, actions etc. but templates,
> especially those containing perl code are still in a textarea input box.
>
> what would anyone recommend as a solution to this.
>
> I'm almost expecting a one-liner like:
>
> { import Templates/MyTemplate }
>
> if import were such a concept in perl
>
> thanks in advance
>
> Woody.
>
>
> --
>
> ---
>
> Richard Wood (Woody)
> Managing Director
> Wild Thing Safaris Ltd.
>
> UK: 2B Habbo St, Greenwich, London
> Dar es Salaam: 5 Ethan St, Mbezi beach
> Arusha: 3 Ebeneezer Rd, Njiro
> PO BOX 34514 DSM
> Office: +255 (0) 222 617 166
> Office Mobile: +255 (0) 773 503 502
> Direct: +255 742 373 327
> Skype: woody1tz
> http://wildthingsafaris.com
>


Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Landon Stewart

On Dec 19, 2016, at 11:48 AM, Alex Hall 
> wrote:

I'm using the Crontool, yes, but I've also been doing searches on the web 
interface to see if I could get this to work. My Crontool syntax is something 
like:

/opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
--search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
--action RT::Action \
--verbose


LastUpdated can change for nearly any change to the ticket if that change is 
recorded (ie. RecordTransaction => 1) like a Status change or an update to the 
watchers etc.  The one you might want to use instead is LastTold which, to my 
knowledge, is when the last correspondence was made.  I may be mistaken here 
though but I think that's what LastTold is for.  Try using LastTold instead of 
LastUpdated.

I'm in the database now, looking at the Tickets table and messing with queries. 
I just tried this, but got an empty set:

select id, LastUpdated from Tickets where LastUpdated <= '3 days ago' order by 
LastUpdated DESC limit 10;

I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is 
something RT interprets before giving the query to the database engine. Still, 
it was worth a shot. I'm now refreshing my knowledge of date math in MySQL so I 
can query exactly what I want, but I hoped UntouchedInHours would do all that 
for me. Oh, and yes, LastUpdated does seem to have normal values in it.

Yes - '3 days ago' is interpreted specially by a module used by RT for things 
like rt-crontool and the search UI within RT.   MySQL has no idea how to 
interpret that though so it won't work there.

They're in GMT time, but they seem to be correct.

All date/time values stored by MySQL are GMT.  One must convert them to GMT 
before storage and convert them to the user's timezone when displaying them.  
RT is aware of this and already takes care of it assuming your time zone 
settings are correct on the server.

--
Landon Stewart
Lead Analyst - Abuse and Security Management
INTERNAP ®
 lstew...@internap.com
 www.internap.com



Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Alex Hall
Well, I found something that works. It's not UntouchedInHours, but this
query seems to return what I want:

select id
from Tickets
where LastUpdated <= (now() - INTERVAL 10 DAYS);

I still have to work out how to email ticket owners, but at least I can get
the right tickets now. Odd that the other way doesn't work. How exactly
does this "10 days ago" syntax get interpreted? Or is it no longer
supported?

On Mon, Dec 19, 2016 at 2:48 PM, Alex Hall  wrote:

> I'm using the Crontool, yes, but I've also been doing searches on the web
> interface to see if I could get this to work. My Crontool syntax is
> something like:
>
> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
> --search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
> --action RT::Action \
> --verbose
>
> Or:
>
> /opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
> --search-arg "status != 'resolved'" \
> --condition RT::Condition::UntouchedInHours \
> --arg-condition 72 \
> --verbose
>
> This shouldn't be modifying tickets, yet I'm seeing tickets created hours
> or minutes ago appearing in the results. Same for my RT web searches for
> similar SQL to what's above.
>
> I'm in the database now, looking at the Tickets table and messing with
> queries. I just tried this, but got an empty set:
>
> select id, LastUpdated
> from Tickets
> where LastUpdated <= '3 days ago'
> order by LastUpdated DESC
> limit 10;
>
> I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is
> something RT interprets before giving the query to the database engine.
> Still, it was worth a shot. I'm now refreshing my knowledge of date math in
> MySQL so I can query exactly what I want, but I hoped UntouchedInHours
> would do all that for me. Oh, and yes, LastUpdated does seem to have normal
> values in it. They're in GMT time, but they seem to be correct.
>
> On Mon, Dec 19, 2016 at 2:37 PM, Matt Zagrabelny 
> wrote:
>
>> Hi Alex,
>>
>> On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall  wrote:
>> > Hello all,
>> > I'm trying to get stale ticket alerts working, so am using the
>> > UntouchedInHours condition. I've also tried, in SQL:
>> > LastUpdated <= '2 days ago'
>> > and similar searches. Yet, I always get the same number of tickets as I
>> get
>> > when I leave the date restriction off completely, and UntouchedInHours
>> is
>> > always giving me tickets opened today.
>>
>> I assume you are using rtcrontool. Correct?
>>
>> How are you alerting?
>>
>> Is the alerting actually "touching" the tickets thus affecting the query?
>>
>> You can query the tickets table directly and see the lastupdated
>> field. See if that field changes how you would expect when you "touch"
>> or "update" a ticket.
>>
>> -m
>>
>
>
>
> --
> Alex Hall
> Automatic Distributors, IT department
> ah...@autodist.com
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Alex Hall
I'm using the Crontool, yes, but I've also been doing searches on the web
interface to see if I could get this to work. My Crontool syntax is
something like:

/opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
--search-arg "status != 'resolved' and LastUpdated <= '3 days ago'" \
--action RT::Action \
--verbose

Or:

/opt/rt4/bin/rt-crontool --search RT::Search::FromSQL \
--search-arg "status != 'resolved'" \
--condition RT::Condition::UntouchedInHours \
--arg-condition 72 \
--verbose

This shouldn't be modifying tickets, yet I'm seeing tickets created hours
or minutes ago appearing in the results. Same for my RT web searches for
similar SQL to what's above.

I'm in the database now, looking at the Tickets table and messing with
queries. I just tried this, but got an empty set:

select id, LastUpdated
from Tickets
where LastUpdated <= '3 days ago'
order by LastUpdated DESC
limit 10;

I'm not surprised I got nothing, as I imagine the '3 days ago' syntax is
something RT interprets before giving the query to the database engine.
Still, it was worth a shot. I'm now refreshing my knowledge of date math in
MySQL so I can query exactly what I want, but I hoped UntouchedInHours
would do all that for me. Oh, and yes, LastUpdated does seem to have normal
values in it. They're in GMT time, but they seem to be correct.

On Mon, Dec 19, 2016 at 2:37 PM, Matt Zagrabelny  wrote:

> Hi Alex,
>
> On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall  wrote:
> > Hello all,
> > I'm trying to get stale ticket alerts working, so am using the
> > UntouchedInHours condition. I've also tried, in SQL:
> > LastUpdated <= '2 days ago'
> > and similar searches. Yet, I always get the same number of tickets as I
> get
> > when I leave the date restriction off completely, and UntouchedInHours is
> > always giving me tickets opened today.
>
> I assume you are using rtcrontool. Correct?
>
> How are you alerting?
>
> Is the alerting actually "touching" the tickets thus affecting the query?
>
> You can query the tickets table directly and see the lastupdated
> field. See if that field changes how you would expect when you "touch"
> or "update" a ticket.
>
> -m
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] constantly seeing error after RT::Extension::Announce

2016-12-19 Thread Matt Zagrabelny
Hi Alex,

On Mon, Dec 19, 2016 at 12:07 PM, Alex Hall  wrote:
> I'm almost positive I ran that, and the page says I could end up with data
> duplication if I run it again. Is there a query I could run in the database
> to check, so I can know for sure? Thanks.

Check the initialdata file for the extension to see what it is
creating in the database. You can definitely query the database.
Perhaps start with the customfields table.

-m


Re: [rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Matt Zagrabelny
Hi Alex,

On Mon, Dec 19, 2016 at 12:54 PM, Alex Hall  wrote:
> Hello all,
> I'm trying to get stale ticket alerts working, so am using the
> UntouchedInHours condition. I've also tried, in SQL:
> LastUpdated <= '2 days ago'
> and similar searches. Yet, I always get the same number of tickets as I get
> when I leave the date restriction off completely, and UntouchedInHours is
> always giving me tickets opened today.

I assume you are using rtcrontool. Correct?

How are you alerting?

Is the alerting actually "touching" the tickets thus affecting the query?

You can query the tickets table directly and see the lastupdated
field. See if that field changes how you would expect when you "touch"
or "update" a ticket.

-m


[rt-users] LastUpdated for tickets not working?

2016-12-19 Thread Alex Hall
Hello all,
I'm trying to get stale ticket alerts working, so am using the
UntouchedInHours condition. I've also tried, in SQL:
LastUpdated <= '2 days ago'
and similar searches. Yet, I always get the same number of tickets as I get
when I leave the date restriction off completely, and UntouchedInHours is
always giving me tickets opened today.

Because the condition and my own query both rely on LastUpdated, I'm
starting to suspect that this field may not be working correctly. Is this a
know problem in 4.4.1, or--more probably--am I doing something wrong? I'm
not getting any errors anywhere, now that UntouchedInHours has been fixed
to use RT::Condition and not RT::Condition::Generic, but neither am I
getting the tickets I should be. Thanks for any ideas!

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] constantly seeing error after RT::Extension::Announce

2016-12-19 Thread Alex Hall
I'm almost positive I ran that, and the page says I could end up with data
duplication if I run it again. Is there a query I could run in the database
to check, so I can know for sure? Thanks.

On Fri, Dec 16, 2016 at 8:53 PM, Todd Wade  wrote:

> On 12/16/16 3:57 PM, Alex Hall wrote:
>
>> Ever since I installed the RT::Extension::Announce plugin, I've seen an
>> error repeated over and over in the log (hundreds of times). It's always
>> the same:
>>
>> couldn't load custom field by 'announcement groups' identifier
>>
>
> Hi Alex,
>
> This sounds like you missed the 'make initdb' step that creates the custom
> field:
>
> https://metacpan.org/pod/RT::Extension::Announce#INSTALLATION
>
> https://st.aticpan.org/source/BPS/RT-Extension-Announce-1.01
> /etc/initialdata
>
> Regards,
>
>
>


-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] external templates

2016-12-19 Thread Woody - Wild Thing Safaris

Hi All,

I've searched long and hard, but to my surprise not found anything that 
relates to external templates - maybe it's so trivially obvious that the 
question is a non question, but i have to ask it.


i have externalised customfields, conditions, actions etc. but 
templates, especially those containing perl code are still in a textarea 
input box.


what would anyone recommend as a solution to this.

I'm almost expecting a one-liner like:

{ import Templates/MyTemplate }

if import were such a concept in perl

thanks in advance

Woody.


--

---

Richard Wood (Woody)
Managing Director
Wild Thing Safaris Ltd.

UK: 2B Habbo St, Greenwich, London
Dar es Salaam: 5 Ethan St, Mbezi beach
Arusha: 3 Ebeneezer Rd, Njiro
PO BOX 34514 DSM
Office: +255 (0) 222 617 166
Office Mobile: +255 (0) 773 503 502
Direct: +255 742 373 327
Skype: woody1tz
http://wildthingsafaris.com



Re: [rt-users] shredding attachments based on date

2016-12-19 Thread Andy Smith
On 2016-12-19, JON 'BOLI' COPELAND wrote:

> you can shred based on sql query, such as
> 
> ./rt-shredder --plugin "Tickets=query,Queue = 'Support' and Status =
> 'deleted';limit,5000" --sqldump /root/bup9.sql --force
> 
> ...so you can change the query as you see fit.

Hi Jon, 

  thanks for your reply, yes I'd seen this but this is using the tickets
plugin so I believe will shred the entire ticket. I want to use the
Attachments plugin, which according to the documentation has no SQL
query support, you appear to only be able to select based on name or
size. Or am I wrong? 

cheers, Andy.

Re: [rt-users] Where to put Crontool conditions?

2016-12-19 Thread Alex Hall
Thanks, I now have a Condition folder alongside the Interface folder.
Sorry; in my previous message, I mistyped the directory quite badly. That's
what I get for going from memory.

On Mon, Dec 19, 2016 at 11:26 AM, Emmanuel Lacour 
wrote:

> Le 19/12/2016 à 17:07, Alex Hall a écrit :
> > Hi list,
> > Where do I put custom conditions for rt-crontool? I'm trying to get
> > UntouchedInHours to work. Its page says to place it in
> > local/RT/bin/... But I have no bin inside local/RT. I'm assuming that,
> > like so many Wiki pages, this is simply not updated for the newer RT
> > versions? What's the right path to use under 4.4.1? Thanks. Oh, the
> > page I'm using:
> > https://rt-wiki.bestpractical.com/wiki/UntouchedInHours
>
>
> like any custom RT scrip condition: local/lib/RT/Condition/ (you need to
> create this directory if not yet done).
>



-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


Re: [rt-users] Where to put Crontool conditions?

2016-12-19 Thread Emmanuel Lacour
Le 19/12/2016 à 17:07, Alex Hall a écrit :
> Hi list,
> Where do I put custom conditions for rt-crontool? I'm trying to get
> UntouchedInHours to work. Its page says to place it in
> local/RT/bin/... But I have no bin inside local/RT. I'm assuming that,
> like so many Wiki pages, this is simply not updated for the newer RT
> versions? What's the right path to use under 4.4.1? Thanks. Oh, the
> page I'm using:
> https://rt-wiki.bestpractical.com/wiki/UntouchedInHours


like any custom RT scrip condition: local/lib/RT/Condition/ (you need to
create this directory if not yet done).


[rt-users] Where to put Crontool conditions?

2016-12-19 Thread Alex Hall
Hi list,
Where do I put custom conditions for rt-crontool? I'm trying to get
UntouchedInHours to work. Its page says to place it in local/RT/bin/... But
I have no bin inside local/RT. I'm assuming that, like so many Wiki pages,
this is simply not updated for the newer RT versions? What's the right path
to use under 4.4.1? Thanks. Oh, the page I'm using:
https://rt-wiki.bestpractical.com/wiki/UntouchedInHours

-- 
Alex Hall
Automatic Distributors, IT department
ah...@autodist.com


[rt-users] RT Stats, whats your best way to do it?

2016-12-19 Thread Joel Bergmark
Hi all,

I'm using the Activity Report function that Best practical was kind enough to 
update for the 4.4.x release, however it has its short comings when other than 
me need to create them and understand them + lack automation.
I'm curious on how you guys are extracting stats from your RT systems?

I want a way to create stats on different queues to get automatic daily and 
weekly reports, but also user stats and then be able to store it to analyze 
trends over past years etc sent over email. Perhaps there some excellent open 
source stats tool for creating sql queries and then create reports on a front 
end, with ability to email out pdfs and spreadsheets for further processing.

Also, want to send out a huge thanks to everyone in the RT Community, you guys 
are amazing and the collective effort produced here is astonishing! RT is truly 
a powerful platform thanks to the collective! I wish you all a happy holiday!

Regards, Joel Bergmark Telecom3 Sverige AB


[Beskrivning: T3]

JOEL BERGMARK
Thirdline support
joel.bergm...@t3.se | www.t3.se
[Beskrivning: 
T3]






Re: [rt-users] shredding attachments based on date

2016-12-19 Thread Jon 'Boli' Copeland
you can shred based on sql query, such as

./rt-shredder --plugin "Tickets=query,Queue = 'Support' and Status =
'deleted';limit,5000" --sqldump /root/bup9.sql --force

...so you can change the query as you see fit.


On 19-Dec-16 2:38 PM, Andy Smith wrote:
>
> Hi all,
>
>   I'd like to remove attachments older than x months from the database
> and thought probably rt-shredder is the tool for this (its not
> something I've used before). Having googled this a bit and checked
> "rt-shredder --plugin help-Attachments" for instructions it looks like
> it may not be possible to use date, can anyone advise? Otherwise I
> guess I need to delete them directly from MySQL, not sure if this will
> make a mess of RT though,
>
> thanks for any help, Andy.
>
>  

-- 
Jon 'Boli' Copeland
Systems Engineer
IT Sales & Services Ltd
All sales enquiries   : sa...@itss.co.tz
All support enquiries : supp...@itss.co.tz
Emergencies Only  : +255 (0) 685 374780



[rt-users] shredding attachments based on date

2016-12-19 Thread Andy Smith
Hi all, 

  I'd like to remove attachments older than x months from the database
and thought probably rt-shredder is the tool for this (its not something
I've used before). Having googled this a bit and checked "rt-shredder
--plugin help-Attachments" for instructions it looks like it may not be
possible to use date, can anyone advise? Otherwise I guess I need to
delete them directly from MySQL, not sure if this will make a mess of RT
though, 

thanks for any help, Andy.