Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Query to return who has approved a ticket with multiple approvers

Huyen Huynh March 24, 2020

My Service Desk tickets have multiple approvers (3 approvers per ticket).  What query do I use to search for who has approved?

Approvals = approved() only informs me if the entire ticket has been approved (doesn't report by individual)

Approvals = approver() returns all tickets (unapproved and approved) belonging to one approver

Approvals = pendingBy() returns all unapproved tickets belonging to one approver

I can't seem to find a way to return only the approved tickets belonging to one approver as Approvals only supports the = operator.

Suggestions?

 

 

1 answer

0 votes
Jack Nolddor _Sweet Bananas_
Atlassian Partner
March 24, 2020

Not sure if this is what are you looking for:

Full approved issues where one of the approvals was user: username1

Approvals = approved() AND Approvals = approver("username1")

 

Pending by other users or Full approved issues where username1 already approved the issue:

Approvals = approver("username1") AND NOT Approvals = pendingBy("username1")

 



Regards

Huyen Huynh March 24, 2020

Thanks for the quick response - unfortunately, I don't think NOT works with approvals.  Both the queries below return the same results:

Approvals = approver("username1") AND NOT Approvals = pendingBy("username1")
Approvals = approver("username1") AND Approvals = pendingBy("username1")

 Suggestions?

Jack Nolddor _Sweet Bananas_
Atlassian Partner
March 25, 2020

Hmmm have you Script Runner for Jira available within your instance?

Huyen Huynh March 25, 2020

Yes, I have ScriptRunner.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events