On Fri, Sep 05, 2014 at 04:46:35PM +0800, Chrilly Cheng wrote:
> I found the cause of this issue. It's not a problem with "midnight Sunday" or
> something, it is about the Custom Field. I set the build-in Starts date to
> "Proposed Start Time(GMT)", then run "Queue = 'ChangeRequest' AND Status !=
> 'Closed' AND Starts > 'midnight Sunday before last' ", it returns the
> expected
> results. But when I change Starts to "'CF.{Proposed Start Time(GMT)}'", it
> returns nothing.
>
> Does 'CF.{Proposed Start Time(GMT)}' return a datetime value? Or, how can I
> set
> Starts and Due date in scrip?If what you want to do didn't work, I wouldn't have told you to keep trying it. What you tried to do works perfectly fine for me locally on 4.2-trunk (what was released last night as 4.2.7rc1). With all the caveats I pointed out about time zones and parsing of sunday. See my example. You've never stated your RT version that I can see, so I assume you're using a version that didn't support this. If you have an example of: exact custom field configuration data in CFs query written and *executed* using the script I sent so that we see the SQL produced, then we can look deeper. -kevin
pgpzt0oLXdhLi.pgp
Description: PGP signature
-- RT Training - Boston, September 9-10 http://bestpractical.com/training
