
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2014 02:40 AM
Can we remove a particular recipient from Email Notification being sent. This Notification is sent to glide field recipients.
Any suggestions will be helpful. Thanks!!
Solved! Go to Solution.
- Labels:
-
Incident Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2014 03:55 AM
this is what I did recently in a before insert business rule on sys_email -
var usermails = current.recipients.split(",");
var usermails1 = current.recipients.split(",");
for(var i=0;i<usermails.length;i++){
var gr = new GlideRecord('sys_user');
gr.addQuery('email',usermails[i]);
gr.query();
if(gr.next())
{
var cuser = gs.getUser();
cuser = cuser.getUserByID(gr.user_name);
if (your conditon to remove the recipient)
{
usermails1.splice(i, 1);
}
}
}
current.recipients = usermails1.toString();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-14-2014 07:12 AM
My suggestion will completely stop a user from receiving only that notification, all other notification types will still be received. That said, it is possible to add a filter per user, so that they will receive the specific notification based on a particular criteria.
Impersonate the user, and go to Notification Preferences as before. Click on the name of the notification on the list, then check the advanced filter box. From there you can add a custom query to filter what the user will receive.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2014 12:15 AM
I like your suggestion. My issue is with user complaining of him receiving two Notifications one for "Assigned To You" and "Updated by" whenever a ticket gets updated. Can i make this Notification customizing of notifications generic for all the user to not receive two notifications. Thanks!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2014 01:06 AM
I see. In this case you may want to change the Weight value on the notification record itself. If two notifications for the same table are sent to a user at the same time, the notification with the higher weight will be sent and the other ignored. So you may want to set the Assigned To You weight to 100 and Updated By to 1. This way the user will only receive the Assigned to You notification. This is of course applicable globally for all users.
Email weighting is described on this wiki page (scroll down slightly to get to the table with Weight in it):
http://wiki.servicenow.com/index.php?title=Email_Notifications#Creating_Email_Notifications

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2014 11:50 AM
Appreciate your OOTB solutions suggested Adam. Thank you.
Unfortunately increasing weight of my notification didn't help. I am trying to figure out something through script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2014 05:42 AM
Adam pinned down your problem. Just find the one that is more important and make it heavier