Use SQL Query to pull out JSD or Jira Core reference link

Originally asked by Jamie Bartlett on 15 February 2021 (original question)


We are doing some analysis on demand coming into the business, now some of this demand will come in via Jira Servicedesk and some will be created directly in Jira Core.
When a ticket gets sent for development e.g sent to Jira Core there is a synchronised ticket reference. JSD will show for example JiraCore-1 and Jira Core would show JSD-1

What I am after is pulling out this link on either side so we can join the 2 systems together and report demand comming in via servicedesk and its performance in Jira Core


Answer by Mariia Horbatiuk on 16 February 2021

Hi Jamie,

Please try to add this rule into the incoming sync rules on the source side:

issue.customFields."remote issue key".value = remoteIssueUrl

and this into the incoming sync rules of the destination side:

if(firstSync){
syncHelper.syncBackAfterProcessing()
}

Hope this helps!