Hi,
I'm trying to pull data into a table from two trees. The card on which I'm trying to perform the query is on the tree 'Planning tree - story' but I also want some data from the 'BP tree'. Bothe trees have card type = story.
I've had a few goes (see below), which should give an idea of what I'm trying to do, but I'm not sure if I'm going totally up the wrong path or if this is even possible.
I'm very new to this so any help would be greatly appreciated.
Thanks. Kim
table query: SELECT 'Story.number', 'Story.name', 'Story.story status', 'Story.planning estimate', 'BP.DSG mingle number' FROM TREE 'BP Tree' WHERE ('type' = 'story' OR 'type' = 'BP') AND 'Sprint' = THIS CARD
table query: ((SELECT 'DSG mingle number' FROM TREE 'BP Tree' WHERE 'type' = 'BP') AND (SELECT name FROM TREE 'BP Tree' WHERE 'type' = 'story' AND 'Sprint' = THIS CARD ))
Comments
8 comments
Hi Kim,
You could directly retrieve data from the Story card without specifying which Tree it belongs to. Please try the below example to query the mingle number, name, status and estimate of all the story cards in a particular iteration.
{{ table query: SELECT number, name, 'Story Status', 'Planning Estimate' WHERE 'type' = 'story' and 'Iteration' = THIS CARD}}
For the second example you provided, you are selecting number from one tree and name from another, if the card is of a particular card type, irrespective of which tree it belongs to, you could directly query it in the format provided above.
Please refer to the 'Table - based on a query' section in the following link: http://www.thoughtworks-studios.com/mingle/3.3/help/macro_reference.html
Hope this helps! Do let me know if you need any further clarification.
-Mansi
Thanks Mansi,
I already have the following table query working on a card in my tree 'Planning tree - story'.
{{
table query: SELECT number, name, 'story status', 'planning estimate' WHERE 'Team' = 'Stream 2' AND 'type' = 'story' AND 'Sprint' = (Next Sprint)
}}
I need to include data from another tree both of which have the story card. I've tried to include the item from the other tree as you've suggested (see below) and whilst the table column appears the data is not being pulled through.
{{
table query: SELECT number, 'CR number', name, 'story status', 'planning estimate' WHERE 'Team' = 'Stream 2' AND 'type' = 'story' AND 'Sprint' = (Next Sprint)
}}
Any further help would be greatly appreciated.
Kim
Hi Kim,
Is the 'CR number' property on the Story card? If the property is not on the Story card, there will be no data to display in the table.
Hi Mansi,
No the 'CR number' is on the Business Proposal card in the BP tree.
That is why I'm trying to pull data from different trees.
Is there a way of including two trees in a table query OR another way of relating trees?
Kim
Hi Kim,
Apologies for the delay in my response. Could you please provide your exact tree structure for the BP tree.
Hi Suzie,
Angela asked me to post my tree configurations.
Planning tree - story Release > Sprint > Story > Defect > Task > Tech Debt > Spike
BP tree BP > Story
I'm writing a query from the Planning tree - story and trying to pull additional data from the BP tree.
Kim
Hi Kim,
As of the current release of Mingle, you will not be able to select the CR value from the BP card while querying data from the Story card on the Planning tree - story.
What you could do currently is use the NESTED IN clause to get is a list of all the stories with a particular CR number or a list of stories with their parent BP stories.
We have captured your scenario as a feature request.
Thanks!
Mansi
Thanks for looking into this Mansi.
Kim
Please sign in to leave a comment.