How to create template variable and pass it into hyperlink

Skydev22
Tera Contributor

Hello community in hr task template i am trying to pass the sys_id of the subject person of the parent task wich is a case this is what i do link.png

This was working fine but for now it seems like when i click into the link it get converted into  $%7bparent.ref_sn_hr_core_case.subject_person_hr_profile.sys_id%7d and not to the sys_id i want any help on this please i tried to do this via business rule it work but the record producer attach to the task generated no longer get displayed to the user .

2 REPLIES 2

Ravi Gaurav
Giga Sage
Giga Sage

Hi @Skydev22 

  • In HR task templates, anything you wrap like ${parent.ref_sn_hr_core_case.subject_person_hr_profile.sys_id} is treated as a template substitution.

  • The platform URL-encodes the ${ } → which is why you see $%7b … %7d.

  • That means ServiceNow didn’t evaluate the expression — it just treated it as literal text.

 

 

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


If you found my response helpful, I would greatly appreciate it if you could mark it as "Accepted Solution" and "Helpful."
Your support not only benefits the community but also encourages me to continue assisting. Thank you so much!

Thanks and Regards
Ravi Gaurav | ServiceNow MVP 2025,2024 | ServiceNow Practice Lead | Solution Architect
CGI
M.Tech in Data Science & AI

 YouTube: https://www.youtube.com/@learnservicenowwithravi
 LinkedIn: https://www.linkedin.com/in/ravi-gaurav-a67542aa/

@Ravi Gaurav  any solution please ?