[rt-users] A script to find certain information in the rt3 database

Vicki Stanfield vicki at progeny.com
Fri Jul 22 11:54:37 EDT 2005


Raed El - Hames wrote:

>This should n't be difficult , write a perl script ..the sql you'll need is:
>select Tickets.id from Tickets left Join Transactions on Tickets.Id =
>Transactions.TicketId left join attachments on Transaction.id =
>Attachments.TransactionId where Tickets.Subject like '%THISPHRASE%' OR
>Attachments.Content like '%THISPHRASE%';
>
>Roy
>  
>
Okay, I have a question now. I have modified the query to be this:

select Tickets.id from Tickets left Join Transactions on Tickets.Id = 
Transactions.ObjectId left join Attachments on Transactions.id = 
Attachments.TransactionId where Tickets.Subject like '%Platform Group%' 
OR Attachments.Content like '%Platform Group%';

I know there are tickets with Platform Group in the subject line, but I 
have waited a long time (maybe 2 hours) and nothing has returned yet 
(although the process is still running). Does this look right to you?

Vicki



More information about the rt-users mailing list