Using RT to run complex queries

Hello all,

I am wondering if I could do something like this via the rt CLI:

  1. List all users

  2. List all tickets including the resolved one

  3. List all tickets filed by a user whose city is, for instance, Chicago.

etc.

Thanks.

Boris.

  1. List all users

rt help ls

  1. List all tickets including the resolved one
  2. List all tickets filed by a user whose city is, for instance, Chicago.

Use the query builder to build a search, then pass that search to the
CLI. Please note, listing all tickets is likely to be expensive if
you have any sort of reasonably sized RT.

-kevin

Hello Kevin,

Thanks a lot for your reply. This makes sense - but the question is, can I
build such a query? Is it possible? I know these are likely dumb questions
but the documentation I found on the Query builder is rather sparse and for
that reason I just don’t know how to do that - or even if it can be done.

Boris.On Thu, Jul 24, 2014 at 11:06 AM, Kevin Falcone falcone@bestpractical.com wrote:

On Wed, Jul 16, 2014 at 02:54:48PM -0400, Boris Epstein wrote:

  1. List all users

rt help ls

  1. List all tickets including the resolved one
  2. List all tickets filed by a user whose city is, for instance, Chicago.

Use the query builder to build a search, then pass that search to the
CLI. Please note, listing all tickets is likely to be expensive if
you have any sort of reasonably sized RT.

-kevin


RT Training - Boston, September 9-10
http://bestpractical.com/training

Thanks a lot for your reply. This makes sense - but the question is, can I
build such a query? Is it possible? I know these are likely dumb questions but
the documentation I found on the Query builder is rather sparse and for that
reason I just don’t know how to do that - or even if it can be done.

You can build such a query, you’ll likely have to use the Advanced tab
to write Requestor.City, but a query to select all tickets, even
the resolved ones, is totally buildable just by clicking on the
buttons in the query builder.

Try building the queries and posting when you have errors. It’s a lot
easier to help someone who’s been trying to sort our a query instead
of answering hypotheticals.

-kevin

Thanks a lot for your reply. This makes sense - but the question
is, can I build such a query? Is it possible? I know these are
likely dumb questions but the documentation I found on the Query
builder is rather sparse and for that reason I just don’t know
how to do that - or even if it can be done.

You can build such a query, you’ll likely have to use the Advanced
tab to write Requestor.City

As a side note, Requestor.City will require RT 4.2.6 or higher – see
the fifth bulletpoint on RT 4.2.6 Release Notes - RT: Request Tracker - Best Practical

  • Alex