[rt-users] using _CurrentUser_ in a saved search?

Kevin Falcone falcone at bestpractical.com
Wed Jan 30 15:38:40 EST 2008

On Jan 30, 2008, at 12:54 PM, Alex J. Avriette wrote:

> I have a search I'm trying to fix that currently looks like:
>  Queue = 'Helpdesk' and Owner = 'aavriette' and LastUpdated < '7  
> days' and LastUpdated > '-7 days'
> The LastUpdated thing smells like a hack to me, but it seems to  
> work. I'd like to be able to say "and Owner = '_CurrentUser_'" but  
> when I do, I get nothing. If I remove the ticks around currentuser,  
> I get
> Error near ->_CurrentUser_<- expecting a VALUE in ' Queue =  
> 'Helpdesk' AND Owner = _CurrentUser_ [ ... ]
> Since we have TPS reports to file weekly, I'm trying to give our  
> users a "rolling 7 day window" of what they've updated in the last  
> week. I want to then save the search, name it appropriately, and  
> then add it to their "at a glance" page so they all have it and  
> don't have to work too hard to get this information.

__CurrentUser__ will work when on the At a Glance page, but isn't  
interpolated when running a normal
saved search (it gets preprocessed before going to the TicketSQL code).
If you save it and add it to At a Glance you should see it work.


> How do I properly use the CurrentUser variable? By the way, I did  
> look at the wiki, and it has the stuff that got me to where I am  
> (it was helpful, like letting me know I could use "negative days")  
> and I used the "google trick" on the mailing list archives, but I  
> didn't see anything appropriate. Apologies in advance if this has  
> been answered; I'll update the wiki with this as an example (seems  
> useful to me) when I get it figured out.
> Many thanks,
> alex
> --
> Alex J. Avriette
> This email should not be considered authoritative or even truthful.
> aim:avriettea -- skype:avriette -- linkedin:http://xrl.us/bfdyi --  
> 858-367-7293
> _______________________________________________
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
> Community help: http://wiki.bestpractical.com
> Commercial support: sales at bestpractical.com
> Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
> Buy a copy at http://rtbook.bestpractical.com

More information about the rt-users mailing list