[rt-users] statistics query

Kelly F. Hickel kfh at mqsoftware.com
Tue Jan 17 11:32:57 EST 2006


> -----Original Message-----
> From: Ruslan Zakirov [mailto:ruslan.zakirov at gmail.com]
> Sent: Tuesday, January 17, 2006 8:21 AM
> To: joseph kacmarcik
> Cc: rt-users at lists.bestpractical.com; Kelly F. Hickel
> Subject: Re: [rt-users] statistics query
> 
> On 1/17/06, joseph kacmarcik <joe at earth.care2.com> wrote:
> > hello's!
> >
> > i'm unable to solve a statistics query problem. specifically, the
> > 'deleted' count is always zero, presumably because of this query:
> >
> > SELECT count(main.id) FROM Tickets main   WHERE ((main.EffectiveId =
> > main.id)) AND ((main.Status != 'deleted')) AND ((main.Type =
'ticket'))
> > AND ( ( (main.Status = 'deleted') ) AND ( (main.Queue = '1') ) AND (
> > (main.LastUpdated <= '2006-01-17 16:00')AND(main.LastUpdated >=
> > '2006-01-16 16:00') ) );
> >
> > i think the problem is:
> >
> > ((main.Status != 'deleted')) ... AND ( ( (main.Status = 'deleted') )
> >
> > when i run the query manually without the !=deleted, the count
returns
> > correct.
> >
> > the only instance i've found in the rt3 codebase is
> > ./lib/RT/Tickets_Overlay.pm, but removing the 'AND ((main.Status !=
> > 'deleted'))' doesn't change the query that's being run (viewing in
mysql
> > log).
> >
> > i'm running rt 3.4.4 and RTx-Statistics v1.8.
> 
> Hello, Kelly, Joseph and co.
> RT doesn't allow searching for deleted tickets unless you use special
> option
> $tickets_obj->{'allow_deleted_search'} = 1
> This functionality is available in 3.4.2 and greater, for earlier
> versions you should patch RT.
> 
> See also usage in RTx::Shredder::Plugin::Tickets; and patch is also
> shipped with shredder distribution.
[Kelly F. Hickel] Also, I've looked at this and can't sync that query up
with the source.  Joseph, can you tell us which report in RTx:Statistics
you're using to generate that query?

-Kelly
> 
> >
> > has someone solved this problem and i've glossed over it in the
lists?
> >
> > thanks!
> > joe
> > _______________________________________________
> > http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
> >
> > Be sure to check out the RT Wiki at http://wiki.bestpractical.com
> >
> > Download a free sample chapter of RT Essentials from O'Reilly Media
at
> http://rtbook.bestpractical.com
> >
> > WE'RE COMING TO YOUR TOWN SOON - RT Training in Amsterdam, Boston
and
> > San Francisco - Find out more at
> http://bestpractical.com/services/training.html
> >
> 
> 
> --
> Best regards, Ruslan.




More information about the rt-users mailing list