Calculated value or query from parent?
![](http://jazz.net/_images/myphoto/c763ea0ae251e0c002b72d13db5837e3.jpg)
I have work items arranged into a hierarchy using parent/child links. I would like to display information from the parent work item in the editor for the child. For example, consider two work items:
I would like to have the editor for ChildWI display the due date from the parent work item. I looked at implementing the above using "Script Based Calculated Values" but it appears that there is no easy way to access the children of a work item from within the script. Can this be done in a calculated value script? Is there another alternative? Suggestions?
Similarly, I would like to have the results of a query for all ChildWIs display the parent's due date in the results. If I can get the calculated value working then this becomes easy. If not, is there another way to get the parent's due date to be displayed in a query's results?
- Rich
Type: ParentWI
id: 1
Summary: Big Task
Due Date: 5/1/2012
Type: ChildWI
id: 2
Summary: Sub Task
I would like to have the editor for ChildWI display the due date from the parent work item. I looked at implementing the above using "Script Based Calculated Values" but it appears that there is no easy way to access the children of a work item from within the script. Can this be done in a calculated value script? Is there another alternative? Suggestions?
Similarly, I would like to have the results of a query for all ChildWIs display the parent's due date in the results. If I can get the calculated value working then this becomes easy. If not, is there another way to get the parent's due date to be displayed in a query's results?
- Rich
One answer
![](http://jazz.net/_images/myphoto/c763ea0ae251e0c002b72d13db5837e3.jpg)
Hi Rich,
By any chance were you able to figure this out? I am looking for a similar solution.
Thanks.
Paul
By any chance were you able to figure this out? I am looking for a similar solution.
Thanks.
Paul
I have work items arranged into a hierarchy using parent/child links. I would like to display information from the parent work item in the editor for the child. For example, consider two work items:
Type: ParentWI
id: 1
Summary: Big Task
Due Date: 5/1/2012
Type: ChildWI
id: 2
Summary: Sub Task
I would like to have the editor for ChildWI display the due date from the parent work item. I looked at implementing the above using "Script Based Calculated Values" but it appears that there is no easy way to access the children of a work item from within the script. Can this be done in a calculated value script? Is there another alternative? Suggestions?
Similarly, I would like to have the results of a query for all ChildWIs display the parent's due date in the results. If I can get the calculated value working then this becomes easy. If not, is there another way to get the parent's due date to be displayed in a query's results?
- Rich