Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

appending users to an assets user type attribute as to not overwrite existing values

Ste404
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 26, 2025

Hi all,

I have a form where someone can select user/s to be added as Business Owners for a process that is an object in Assets.

Select the business process.  Select the user or users on the form, submit the request.  When approved those users are added to the user attribute in assets, works fine.

Currently if there is already a user in the attribute it just gets overwritten.  I want to just append the values from the work item process to the attribute in assets.   If there is nothing there then the values are added, if there is something there then the new users are just appended and the stored user count grows.

I have an automation that currently now stores a various of the accountid/s of the values selected on the work item.  I also do a lookup and grab any accountids that may already exist in Assets.

What I can't figure out is the JQL to edit the object attributes to append the new to the old.

Can anyone guide me on this one.

Thanks

1 answer

1 vote
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 27, 2025

Hi @Ste404 

This may not be a JQL matter and instead an adjustment is needed to your automation rule in the list / value handling.

To provide more context for the community to help, please post the following:

  • an image of your complete automation rule in a single image for continuity
  • images of any relevant actions / conditions / branches
  • an image of the audit log details showing the rule execution

 

Kind regards,
Bill

Ste404
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 27, 2025

I have no idea why I can't reply with an image?!

I collect existing user accountid from Assets if there are any stored for the selected user.
{{#lookupObjects.get(0).Alternate Approver}}{{accountId}}{{^last}},{{/}}{{/}}

I collect the accountid for the new users on the work item
{{#issue.customfield_10240}}{{accountId}}{{^last}},{{/}}{{/}}

these are variables and I combine them.
Existing: 60ad2d2a06bf0c006a42fa84,60ad32ec411c2200684cd355,60ad34a79e21bd0071e6f4db
New: 60ad3708411c2200684d57fd,62b910c0268cac6e31c31251


In a for AQL loop I am editing the object attributes, but it is failing as I assume it is trying to write these as a string and not the correct value for the user type in assets


Attribute value is not valid on Objects
PPL-200 (Alternate Approver = 60ad2d2a06bf0c006a42fa84,60ad32ec411c2200684cd355,60ad34a79e21bd0071e6f4db,60ad3708411c2200684d57fd,62b910c0268cac6e31c31251)
Unable to update objects

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events