- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2015 12:49 PM
Hi ServiceNow Community Developers,
I have the following situation - I have a Requested Item form (sc_req_item table) that has catalog task (sc_task table) related list. When the work notes changes in the Requested Item form I need to send a notification to the assignment group that is in the catalog tasks related list. Would you please advise as to how do I dot walk from the sc_req_item table to the sc_task table to pick up the assignment group that is in this table and specify that as the group i want emails to be sent to. . I can see the 'Show related fields' link but I cannot tell which field to choose that will let me dot walk to the assignment group that is defined in the catalog task (sc_task) table. Please help.
Thanks,
Johannes
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2015 03:04 PM
you can only dot walk from a child to a parent... which is why this didn't work...
how to get the additional recipients isn't to hard.. write a mail notification script that looks up the people that have tasks assigned to them with that item as a parent then use "email.addAddress("cc",splitThis[i]);" to add the user to the email <put the user in where i have splitThis array>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2015 01:15 PM
Hi,
In fact, you can't dot walk, because the relationship is done from [sc_task] to [sc_req_item], so, yo need to script a GlideRecord Query at [sc_task] using .request_item field to filter with the request_item reference
Best Regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2015 02:59 PM
Hi German,
Thanks for your response. This explains why I can't do it then because I have done some complex dot walking before but for some reason I could not figure out how to do it on this one.
My next question though is if I script and derive the group that I would like the emails to be sent to how do I then specify that group inside the email notification record or do I have to do that elsewhere?
Thank you in advance for your help.
Johannes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2015 03:04 PM
you can only dot walk from a child to a parent... which is why this didn't work...
how to get the additional recipients isn't to hard.. write a mail notification script that looks up the people that have tasks assigned to them with that item as a parent then use "email.addAddress("cc",splitThis[i]);" to add the user to the email <put the user in where i have splitThis array>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2015 03:15 PM
Hi Doug,
If I want to send it to the assignment group though can i do so directly or i will have to breakdown the group into its members and send it individually to members like you describe above.
Thanks,
Johannes