I have this smart value that I am utilizing from the description field to extract the information between pieces of data in the description field in automation to populate a customized field in the Jira instance:
{{issue.description.substringBetween("Name: GMRCNT\","Host Name"}}
I can't get this work anyway possible. I've looked at the following links of documentation regarding smart value:
https://confluence.atlassian.com/sneaky/jiracorecloud/advanced-field-editing-json-996709925.html
https://support.atlassian.com/jira-software-cloud/docs/smart-values-text-fields/
https://community.atlassian.com/t5/Jira-Software-questions/invalid-json-in-automation-for-jira/qaq-p/1506271
And a few other kb articles. I have had all kinds of errors, but this is the last one It gives me:
Failed to get value for issue.description.substringBetween("Name: GMRCNT\","Host Name")
I utilized this same format substring in another automation rule by populating a field with a description and it works fine with no errors:
{{issue.description.substringBetween("Case # ","Subject:")}}
Both my fields are the same format and on the screens.
Any suggestions on what to try to get the information between 2 pieces of data in the Description jira field???
Hi Nita,
Can you please share your audit log when the rule is triggered?
Regards,
Fabian
Hi @Nita Brumbaugh
I wonder if the slash character is not being accepted in the search parser. Please try to remove that character to see if it works. If so, that would isolate the problem and then you could try to either escape the character or just use remove() after pulling out the substring.
Best regards,
Bill
I did remove the / and it still doesn't work. The unfortunate part is that I need the text right after the GMRCNT\
do you mean to extract the value with the / and then remove the /? Not sure what you me about escape the character
Thanks
Hi! Okay I did some quick tests, and found that the substringBetween() is parsing stuff following the \ as a prefix for a special character. If you change your search to use \\ in place of any \ it should work.
It looks like you're new here. Sign in or register to get started.