System updating the additional comments field which triggers blank emails
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2016 09:08 PM
Hi SNOW Enthusiasts,
I have been facing a problem for quite a while now which my client is complaining of and I still could not find a way to resolve.
The Story is :
When ever a Request item/incident ticket is commented, a mail notification is triggered to requester. Lately I have observed that the system is changing the additional comments even if it is blank and as a result sends an email to the requester. I have seen this issue a numerous time now where the comments are updated (totally blank) and then triggered a notification.
How can we stop this update of blank additional comments OR what may be the reason that a blank comment is updated?
Thanks,
Arnab
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2016 09:20 PM
Sounds like a weird problem.
I would try and figure out what is causing the blank updates by creating a Business Rule to do some logging.
Condition: current.comments.changes()
Script: gs.log('Comments have changed on ' + current.number + ' by ' + gs.getUserName() + '.\nComments: "' + current.comments + '"', 'Comments issue');
You can change the conditions on the Email Notification to prevent it from sending. Can you post a screenshot of your Email Notification?
The out-of-the-box notification uses 'Send when' is 'Record is inserted or updated'. But I've always found events to be more accurate for Email Notifications. So you could switch to an Event-based trigger.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2016 09:33 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2016 09:38 PM
What does the code look like that is firing the sc_req_item.commented event?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2016 09:38 PM
Also Geoffrey, I am unable to reproduce this issue. This is also a reason I'm not able to solve this issue. This happens sometimes and anonymously, not every time.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2016 09:39 PM
There will be some reason behind it. We just need to find it.