It's all about the answers!

Ask a question

Query and Approvals


Kevin Zemanek (2454825) | asked Apr 13 '10, 10:55 a.m.
I am trying to query a set of work items where one of the criteria is that an approver is NOT a particular person (person X). The work items may have 0-n approval records.

What I am doing:

I am adding the criteria:

"Approvals>Approver>E-Mail does not contain" personX@abc.com

What I am seeing:

Right results:
If the work item has no approval records, that work item is returned.
If the work item has >= 1 approval records, none of which are owned by person X, it is returned.
If the work item has only 1 approval record (owned by person X), it is not returned.

Incorrect results:
If the work item has > 1 approval records AND person X owns one of those records the work item IS returned by the query.

I have tried using both the approver's name and e-mail, and using "is not" and "does not contain" - none of these seem to provide the correct results.

Suggestions appreciated.

Thanks.

3 answers



permanent link
Patrick Streule (4.9k21) | answered Apr 15 '10, 5:15 a.m.
JAZZ DEVELOPER
I am adding the criteria:

"Approvals>Approver>E-Mail does not contain"
personX@abc.com

What I am seeing:

Right results:
If the work item has no approval records, that work item is returned.
If the work item has>= 1 approval records, none of which are owned
by person X, it is returned.
If the work item has only 1 approval record (owned by person X), it is
not returned.

Incorrect results:
If the work item has> 1 approval records AND person X owns one of
those records the work item IS returned by the query.

I have tried using both the approver's name and e-mail, and using
"is not" and "does not contain" - none of these
seem to provide the correct results.

Suggestions appreciated.

Unfortunately, there is currently no way to express "None or All of the
approvals". The condition refers always to a single approval. In the
incorrect case, there is an entry where the condition is true, so the
work item is returned.

The query basically expresses:
All work items that have an approver whose e-mail does not contain...

and not:
All work items where *all* approvers' e-mail does not contain...

--
Regards,
Patrick
Jazz Work Item Team

permanent link
Ming-Chieh Yu (6) | answered Apr 20 '10, 4:56 p.m.
I am adding the criteria:

"Approvals>Approver>E-Mail does not contain"
personX@abc.com

What I am seeing:

Right results:
If the work item has no approval records, that work item is returned.
If the work item has>= 1 approval records, none of which are owned
by person X, it is returned.
If the work item has only 1 approval record (owned by person X), it is
not returned.

Incorrect results:
If the work item has> 1 approval records AND person X owns one of
those records the work item IS returned by the query.

I have tried using both the approver's name and e-mail, and using
"is not" and "does not contain" - none of these
seem to provide the correct results.

Suggestions appreciated.

Unfortunately, there is currently no way to express "None or All of the
approvals". The condition refers always to a single approval. In the
incorrect case, there is an entry where the condition is true, so the
work item is returned.

The query basically expresses:
All work items that have an approver whose e-mail does not contain...

and not:
All work items where *all* approvers' e-mail does not contain...

--
Regards,
Patrick
Jazz Work Item Team

Hi Patrick

How would you recommend searching for all work items that do not have a particular person as an approver?

permanent link
Sheetal Desai (91188) | answered Apr 22 '10, 2:43 p.m.
I have a related issue.

I want to display the approval > state in the query but there is no way to add this to the result layout that I can find.

Please let me know if there is a way to see the approval state as a column on the WI query

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.