On Wed, 2008-05-21 at 17:19 +0200, Alain Sips wrote:
> Hello,
>
> Attached to our tickets, we have a custom field called 'Reminder
> Interval'. In this field, a number is written in minutes. I would like
> to create a query that checks if the last update has been longer that
> the amount of minutes in this field. I would think that that query would
> look like this:
>
> Status = 'open' AND 'CF.{Productomschrijving}' IS NOT 'NULL' AND
> LastUpdated < 'CF.{Reminder Interval} minutes ago'
>
> However, there is for example a ticket that has 15 in that custom field
> and that hasn't been updated in 2 hours.
> If I have the query:
> Status = 'open' AND 'CF.{Productomschrijving}' IS NOT 'NULL' AND
> LastUpdated < '15 minutes ago'
> this gives back the 1 result.
>
> However if I use the first query, no results are returned.
> Am I using an incorrect syntax?Total guess here: Is the db field some sort of text (varchar, etc)? If so you may need to cast before doing a comparison. -- Matt Zagrabelny - [EMAIL PROTECTED] - (218) 726 8844 University of Minnesota Duluth Information Technology Systems & Services PGP key 1024D/84E22DA2 2005-11-07 Fingerprint: 78F9 18B3 EF58 56F5 FC85 C5CA 53E7 887F 84E2 2DA2 He is not a fool who gives up what he cannot keep to gain what he cannot lose. -Jim Elliot
signature.asc
Description: This is a digitally signed message part
_______________________________________________ http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users Community help: http://wiki.bestpractical.com Commercial support: [EMAIL PROTECTED] Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com
