Generate a unique consecutive id for a workitem type
How can I generate a unique string id for records of a work item type. For instance, I have a work item of type SCR (custom type). I would like the first SCR to get an id of SCR00001 (value of a custom attribute) and the second one to get an id of SCR00002 and so on. Is this possible with RTC? This was really easy to perform with ClearQuest. Are there any code samples etc. available that show how to do this? Thanks. |
2 answers
This is not available out of box with RTC, since our work item ID's are purely numbers. What you could do is set up a script based condition so that when a new work item is created, it sets a custom attribute to your SCR number + 1. Therefore, all your queries can point to that custom attribute and not the ID of the work item.
Comments
Prakash Behrani
commented Jul 16 '13, 1:05 p.m.
Stepanie, How would I get the previous SCR number? Is there is global attribute which can hold a SCR number value for the last SCR that was created?
Thanks. |
You would have to find a way to script it.
There is nothing out of the box that would suffice your request, and thus no global attributes. This would all need to be customized. |
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.