Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Operational Participant referring to the the deleted attribute

 Hi All,

I encountered a plugin which need to access an attribute and then does some stuff around that.

My case is I have an attribute which is an integer type as part of the requirement we need to modify it to use the enumeration so I deleted the existing attribute which is of type integer and then created anew attribute whose type is enum.

now MY plugin worked fine when it is using the Integer filed and now I change my code to access the new attribute but some how it is returning null.

to my surprise it is returning an object when I use the old attribute id (The workitem template is no more using that old attribute).

How the plugin is able to access a deleted attribute?

Thanks
Surender.

0 votes

Comments

Workitems created before your change will still have the old attribute. Once created they cannot be deleted.

I`m not able to get the details of the new attribute Even when I tried it for the new work items which are using the new attribute.


Thanks
Surender

a little more info please..

the IDs for the two attributes (old and new) are different, correct?

you cannot 'change' an attribute type.

the old attribute ID will still exist, because some the workitems have it.  u cannot reuse the ID.



One answer

Permanent link
You can not reuse the ID with a different attribute type. You could have - if planned carefully - created a migration tool that translated the old number into an enumeration literal.

Secondly, enumerations are handled different from just an int number if it comes down to its values. See https://rsjazz.wordpress.com/2012/08/20/manipulationg-work-item-enumeration-values/ for some hints. In a server participant, I believe you would use IAuditableServer or IAuditableCommon rather than IAuditableClient, but the rest of the API should be pretty much the same.

0 votes

Your answer

Register or log in to post 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,930

Question asked: Nov 15 '14, 3:44 p.m.

Question was seen: 2,865 times

Last updated: Nov 17 '14, 5:33 a.m.

Confirmation Cancel Confirm