Need help with RT-SQL on days calculation

To list,

I’ve been to the wiki and did some googling but no joy. Most likely my
inexperience with both.

I’m trying to run a query in RT that will give me all “open” tickets that
are due within the next 30 days. Simple enough, but I can’t seem to get the
syntax right. I have:

( Status != ‘resolved’ AND Status != ‘rejected’ ) AND Due < (today + 30
days). I’ve tried variations of ‘Today’ and no joy.

Help please?

Thanks.

Kenn
LBNL

To list,

I’ve been to the wiki and did some googling but no joy. Most likely my
inexperience with both.

I’m trying to run a query in RT that will give me all “open” tickets that
are due within the next 30 days. Simple enough, but I can’t seem to get the
syntax right. I have:

( Status != ‘resolved’ AND Status != ‘rejected’ ) AND Due < (today + 30
days). I’ve tried variations of ‘Today’ and no joy.

Help please?

Thanks.

Kenn
LBNL

What about something like:

Due < ‘30 days from now’
AND Due > ‘today’

with the additional list of statuses?

Regards,
Ken

That should also be:

Due > ‘1 day ago’

and not:

Due > ‘today’

KenOn Mon, Sep 13, 2010 at 12:47:11PM -0500, Kenneth Marshall wrote:

On Mon, Sep 13, 2010 at 10:38:54AM -0700, Kenneth Crocker wrote:

To list,

I’ve been to the wiki and did some googling but no joy. Most likely my
inexperience with both.

I’m trying to run a query in RT that will give me all “open” tickets that
are due within the next 30 days. Simple enough, but I can’t seem to get the
syntax right. I have:

( Status != ‘resolved’ AND Status != ‘rejected’ ) AND Due < (today + 30
days). I’ve tried variations of ‘Today’ and no joy.

Help please?

Thanks.

Kenn
LBNL

What about something like:

Due < ‘30 days from now’
AND Due > ‘today’

with the additional list of statuses?

Regards,
Ken

RT Training in Washington DC, USA on Oct 25 & 26 2010
Last one this year – Learn how to get the most out of RT!

or:

Due > ‘1970-01-02’

(if you’re interested in overdue tickets as well)

Cheers,
PaulOn 09/13/2010 10:55 AM, Kenneth Marshall wrote:

That should also be:

Due > ‘1 day ago’

and not:

Due > ‘today’

Ken

On Mon, Sep 13, 2010 at 12:47:11PM -0500, Kenneth Marshall wrote:

On Mon, Sep 13, 2010 at 10:38:54AM -0700, Kenneth Crocker wrote:

To list,

I’ve been to the wiki and did some googling but no joy. Most likely my
inexperience with both.

I’m trying to run a query in RT that will give me all “open” tickets that
are due within the next 30 days. Simple enough, but I can’t seem to get the
syntax right. I have:

( Status != ‘resolved’ AND Status != ‘rejected’ ) AND Due < (today + 30
days). I’ve tried variations of ‘Today’ and no joy.

Help please?

Thanks.

Kenn
LBNL

What about something like:

Due < ‘30 days from now’
AND Due > ‘today’

with the additional list of statuses?

Regards,
Ken

RT Training in Washington DC, USA on Oct 25 & 26 2010
Last one this year – Learn how to get the most out of RT!

RT Training in Washington DC, USA on Oct 25 & 26 2010
Last one this year – Learn how to get the most out of RT!

Kenneth, All,

Thanks. That did it. I see my problem was using parenthesis and not using
quotes.

Thanks again.

Kenn
LBNLOn Mon, Sep 13, 2010 at 10:55 AM, Kenneth Marshall ktm@rice.edu wrote:

That should also be:

Due > ‘1 day ago’

and not:

Due > ‘today’

Ken

On Mon, Sep 13, 2010 at 12:47:11PM -0500, Kenneth Marshall wrote:

On Mon, Sep 13, 2010 at 10:38:54AM -0700, Kenneth Crocker wrote:

To list,

I’ve been to the wiki and did some googling but no joy. Most likely my
inexperience with both.

I’m trying to run a query in RT that will give me all “open” tickets
that
are due within the next 30 days. Simple enough, but I can’t seem to get
the
syntax right. I have:

( Status != ‘resolved’ AND Status != ‘rejected’ ) AND Due < (today +
30
days). I’ve tried variations of ‘Today’ and no joy.

Help please?

Thanks.

Kenn
LBNL

What about something like:

Due < ‘30 days from now’
AND Due > ‘today’

with the additional list of statuses?

Regards,
Ken

RT Training in Washington DC, USA on Oct 25 & 26 2010
Last one this year – Learn how to get the most out of RT!