Automation to find duplicate issues

Rasa
Contributor
October 10, 2024

Hi 

I want to create problem from duplicate event (ITIL Process).

So i need to find duplicate issue that are create. (Like lookupissues in cloud)

Can someone help me please...

2 answers

1 accepted

0 votes
Answer accepted
Dick
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.
October 10, 2024

Hi @Rasa 

You first need to define what you rank as a duplicate. Which fields are important and in what way should the comparison between two issues on that field yield you a yay or nay identical?

Do know you can start a string comparison with ~ it reads as "like".

Try to put your query into normal words first. Syntax of the automation comes later.

 

Hope we can help you once your question is a bit more clear,

Dick

By voting for helpful posts and marking answers to your question, you're helping people with similar questions find a solution more quickly. Sharing is caring applies to knowledge as well :)

Rasa
Contributor
October 10, 2024

I want to write an automation which start when an issue create 

When issue create automation search and find issues with simailar summary like triger issue and then create a problem with the same summary and link the all similar issues.

In cloud i can search for thos issues with "lookup issues " in automation but in datacenter i can not find enything for this search.

Dick
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.
October 10, 2024

Hi @Rasa 
Your question has become a lot clearer due to your added text. 

  • We're talking about an on create trigger
  • The comparison field is summary
  • LookupIssues are available in datacenter, so that's hopeful

Can you post a picture of the cloud automation, so we can adapt that to datacenter Jira?

Hope this helps,

Dick

By voting for helpful posts and marking answers to your question, you're helping people with similar questions find a solution more quickly. Sharing is caring applies to knowledge as well :)

Rasa
Contributor
October 10, 2024

Screenshot_20241010_130925_Chrome.jpg

Rasa
Contributor
October 10, 2024

I want anything like this automation in datacenter

The picture is on cloud version

Dick
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.
October 10, 2024

Thank you Rasa,

The problem is in your JQL where you construct the lookup issues:

There is no need to escape the quotes: 

"{{triggerissue.summary}}"  suffices. 

 

Hope you get it to work now,

Dick

By voting for helpful posts and marking answers to your question, you're helping people with similar questions find a solution more quickly. Sharing is caring applies to knowledge as well :)

 

-------------------------------------------------------------------------------------------------

example at datacenter Jira

 

Q1.png

 

 

Like Rasa likes this
Rasa
Contributor
October 10, 2024

There is not lookupissue action in jira automation on DC as second line in picture you send.):

Dick
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.
October 10, 2024

Well, I'm sorry to have to disagree with you, but I'm really quite sure we're running the datacenter version of Jira. But maybe it's a different version than yours:

We're on long term version 9.12.11. 

Maybe you're running a different version of Jira?
You can find that data on: Administration - Applications - Versions & Licenses

 

Just trying to help you here

Dick

By voting for helpful posts and marking answers to your question, you're helping people with similar questions find a solution more quickly. Sharing is caring applies to knowledge as well :)

 

 

Like Rasa likes this
Rasa
Contributor
October 10, 2024

Thank you so much dear Dick


The puzzle is solved. 

My jira version is 9.2:)

Like Dick likes this
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.
October 15, 2024

Hi @Dick 

An FYI about your statement:

There is no need to escape the quotes: 

"{{triggerissue.summary}}"  suffices. 

 

Using the CONTAINS ~ operator like this"

summary ~ "{{triggerIssue.summary}}" 

Will fuzzy match on any of the words in the summary, in any order, and may include other words.

 

When a more exact match is needed, the exact phrase syntax is used by adding the escaped quotation marks:

summary ~ "\"{{triggerIssue.summary}}\"" 

That could still have additional matches, with leading or trailing text around the match text.  For example, if the trigger issue summary was "this story is about squirrels", matches could be on the following:

  • this story is about squirrels
  • here is some leading text and this story is about squirrels
  • this story is about squirrels and here is some trailing text
  • here is some leading text and this story is about squirrels and here is some trailing text

 

When a true, exact match is needed, the rule will also need a smart value condition to test "equals" between the values.

 

Kind regards,
Bill

Like # people like this
Rasa
Contributor
October 15, 2024

Hi Bill

Your suggestion was very useful. 

Thanks. 

 

Like Bill Sheboy likes this
Dick
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.
October 17, 2024

Thank you @Bill Sheboy for clarifying.

I'm happy to see that it acts the same as in the Google search bar. (only need to remember a single syntax)


For @Rasa the usage of the quotes would depend on her needs. (exact match: use quotes, fuzzy match: do not use quotes).

 

It all comes together happily,

Dick

 

Like Bill Sheboy likes this
4 votes
mararn1618 _secretbakery_io_
Atlassian Partner
November 11, 2024

Hey @Rasa, I just wanted to link an article I recently wrote about how to write an automation rule to manage duplicate tickets.

It's very similar to the accepted solution, but I think other people could benefit from the additional detail and illustrating images in that article.

I hope that's ok.

Suggest an answer

Log in or Sign up to answer