AnsweredAssumed Answered

How to query for defects only in open projects

Question asked by 2eaace42220b1642471856e143f2d7a1 on May 1, 2015
Latest reply on Jun 19, 2015 by AsAForRally,Glenn
I built a custom search tool to allow searching Rally via the Web API from other applications and I've run into an issue.  Right now I am allowing defects to be searched but I noticed that defects are coming back in the search results that are related to a project that is closed.  I need to filter these out.  I am wondering if there is a way to access attributes on a referenced object when querying another object, for example, if I have a query to search for defects where the name contains some text, such as https://rally1.rallydev.com/slm/webservice/v2.0/defect?query=(Name contains "keyword"), can I include something in that query to say that I only want defects for open projects by using the Project attribute on Defect, such as Project.State equals "Open".  Basically I'm wondering if there is a way to do it in one query in an OData-ish format. Or as an alternative, if I separately query for a list of all open projects, could I add conditions to the query to say something like (Name contains "keyword") AND (ProjectId = ... OR ProjectId OR ...)?  Any thoughts or suggestions are much appreciated.

Outcomes