How can I fetch the latest comment of incident and display it in an email templates of sow.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
How can I fetch the latest comment (Additional comments) from an incident and display it in an email template in Service Operations Workspace? I want the RITM number of most recent comment from the Activities section of the incident to be included in the email template. How can this be achieved?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
Hey
To fetch the latest “Additional comments” from an Incident and show it in an email template, you need to use a mail script because these comments are stored in the sys_journal_field and not directly on the Incident record. In the script, query this table with element_id = current.sys_id and element = comments, sort by created date in descending order, and fetch the latest entry, then print its value in the template; if you also need the related RITM number, you can fetch it from the associated record and include it along with the comment in the email output.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
you can't get it directly
you need email script for this
what did you start and where are you stuck?
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
