question about creating report
Hi all,
If I wanna get the WI_COUNT of the workitem of which type is "task" or "defect", how can I create this constraint when editting the data set. Thanks |
3 answers
On 12/14/2009 11:38 AM, luyaoben wrote:
Hi all, Let's assume you're using the LIVE_WORKITEM_CNT table. Add a parameter to your data set for WI_TYPE. Then, on the parameters page in the data set editor, specify a default value for WI_TYPE. To do this, you need to know the ids for the work item states "task" and "defect". If you're using one of our out-of-the-box templates, the ids are probably just "task" and "defect". So construct a default value that looks exactly like this: '\'task\',\'defect\'' Basically, it's comma-separated escaped single-quoted strings. So this will mean your data set will only return values for which WI_TYPE is in the set {task, defect}. Therefore WI_COUNT (assuming you're selecting that column) will contain the sum of the number of those work item types. Hope this helps. james RTC Reports Team Lead |
On 12/14/2009 11:38 AM, luyaoben wrote: Hi all, Let's assume you're using the LIVE_WORKITEM_CNT table. Add a parameter to your data set for WI_TYPE. Then, on the parameters page in the data set editor, specify a default value for WI_TYPE. To do this, you need to know the ids for the work item states "task" and "defect". If you're using one of our out-of-the-box templates, the ids are probably just "task" and "defect". So construct a default value that looks exactly like this: '\'task\',\'defect\'' Basically, it's comma-separated escaped single-quoted strings. So this will mean your data set will only return values for which WI_TYPE is in the set {task, defect}. Therefore WI_COUNT (assuming you're selecting that column) will contain the sum of the number of those work item types. Hope this helps. james RTC Reports Team Lead Hi James, I want to modify the "Open Work Item by Type" in report template to customize a report template. And I want to specify the WI_TYPE is "com.example.workItemType.myWorkItem". Then how to make the modification? There are several data sets in "Open Work Item by Type", and what is the relationship between them? Regards |
On 12/15/2009 8:37 PM, luyaoben wrote:
jmoodywrote: Hi James, I want to modify the "Open Work Item by Type" in report template to customize a report template. And I want to specify the WI_TYPE is "com.example.workItemType.myWorkItem". Then how to make the modification? There are several data sets in "Open Work Item by Type", and what is the relationship between them? Regards So let's assume you want to hard-code the WI_TYPE. The data set you want is simply called "Data Set". Edit that data set. On the Fact Information page, select WI_TYPE as a Parameter. Then click on the Parameters page, and for the default value for WI_TYPE, enter 'com.example.workItemType.myWorkItem' (including the single quotes). Note that unfortunately adding this parameter may cause the default parameter values (and report parameter bindings) for subsequent parameters to be lost, so you'll have to re-enter those manually. (Might help to have a backup copy of this file that you can copy and paste from). Hope this helps. james RTC Reports Team Lead |
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.