Translate Reporter_Account_Id

jeff.rhoad February 1, 2024

Is there a way to translate the jira_issue.reporter_account_id to the object key of the reporter in asset_object table? 

I am trying to create a list of tickets reported by location and I need the object key of the reporter to determine their location. 

Thanks. 

2 answers

0 votes
Tracy Chow
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 1, 2024

Hi Jeff,

Is your Jira issue linked to the reporter's object in Assets through a Jira custom field? If so, you can use the "Assets object issue mapping" table

Let me know if that works for you or if you have further questions.

Cheers,
Tracy

jeff.rhoad February 2, 2024

Yes I can link from Jira_issue to asset_object_issue_mapping via the issue id. But how do I tell which object in the asset_object_issue_mapping table is the issue reporter?

Tracy Chow
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 2, 2024

If you have a specific asset type set up for your user objects, you can add a query filter to filter for the desired object type, such as "Assets Type"."Name" = 'User'.

Does this approach work for your current setup? 

0 votes

First do a 'Lookup Objects' call first for schema = People and the query  is User = {{issue.reporter}}

Then you can used the resulting Lookup object/s  (in above scenario it would be called 'User').  So, you could print out the results, say as Comment or Log action, using code like this:

reporter ID = {{issue.reporter.accountId}}
{{#lookupObjects}}
* {{User}} , {{User.displayName}} , {{User.accountId}}
{{/}}

For me the results look like:

reporter ID = 6406540e9ce2cd2c240fc14c

  • 6406540e9ce2cd2c240fc14c , Rodney D'Souza , 6406540e9ce2cd2c240fc14c

As you can see displayName and accountId keywords you can use.

 

If this helps, let me know, and 'Accept' this answer

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events