Last 3 comments and work notes are appearing in the email notification instead of only last comment.

Ksnow
Tera Contributor

Hi all, @shloke04 

Additional comments and work notes are updating last 3 messages in the email notification instead of last one.

We have issue with the only one instance but the same development is available in the both instances(Test & other non- prod environment)

For example: if user commented in the incident like Test-1 initially and later Test-2 both the comments are showing where ever comments field used in the email notifications.


What exactly to be checked to rule out the issue?

Thanks,

Ksnow

11 REPLIES 11

Musab Rasheed
Tera Sage
Tera Sage

Hi Ksnow,

You have to use mail script for this, In notification add this line of code : ${mail_script:getLastComment}

find_real_file.png

then create email script and add this line of code:

template.print(current.comments.getJournalEntry(1));

 

find_real_file.png

 

Please hit like and mark my response as correct if that helps
Regards,
Musab

Hello,

After the upgrade, one property changed value from 1 to 3

To solve this its OK to change change back from 3 to 1

Hope this helps.

/Petr

 

1a.jpg

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

So are you saying the same notification is behaving differently in both the instances?

can you share what configuration/script you are using?

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi Ankur, 

Yes same notification is behaving differently in both the instances.

There is no script, this is the email notification.

find_real_file.png

In all notification where ever we are using "Comments" for all those notification it showing like below. Highlighted in yellow are the comments

find_real_file.png