It's all about the answers!

Ask a question

How can I query all work items that have the same owner and approval?

S S (141418) | asked Mar 19 '14, 10:09 a.m.
Is this programmatically possible?  i.e. I want to find all work items that have Bob as the both the Owner and the Approver of a work item.

Accepted answer

permanent link
Piotr Aniola (3.7k11738) | answered Mar 19 '14, 10:43 a.m.
It's possible to do "return all workitems where owner = 'Bob' and approver = 'Bob'.
It's not possible to do "return all workitems where owner = approver".
If the latter use case is the desired one, I suggest to create a custom report that returns such workitems.
S S selected this answer as the correct answer

S S commented Mar 19 '14, 11:21 a.m.

Yup, was looking for the latter case. Is there anyway to get a resulting column from a query with the name of the approver listed? I.e. query on all work items for any owner but have RTC return the owner for each work item.

sam detweiler commented Mar 19 '14, 11:27 a.m.

sadly, no.. approval data is not displayable/exportable. 

One other answer

permanent link
sam detweiler (12.5k6195201) | answered Mar 19 '14, 10:36 a.m.
 seems pretty straight forward.. if you are looking for 'Bob'

if you are looking for cases where the two userids are identical.. then I don't think you can do that in the query editor.

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.