how to send 2 different email to different people.

TMKAM
Tera Contributor

I have an issue to create a workflow and notification as per below scenario.

 

scenario 1

1. user submit catalog request.

2. 1st email approver is to HOD number 1 with different email content.

3. Approved by the 1st email approver which is the HOD number 1.

4. 2nd email approver is to HOD number 2 with different email content.

5. Approved by the 2nd email approver which is the HOD number 2.

6. email notification send to the requester.

 

I have created 2 email notification.

1st email approver is HOD number 1.

2nd email approver is to HOD number 2.

 

I attach the workflow and notification for your reference.

20 REPLIES 20

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @TMKAM 

The issue is that both email notifications have almost the same conditions, which is why the second one didn’t work.
For the second email notification, you need to add one more condition to differentiate it from the first.

Think about adding a condition like:
“Send email only when HOD1 has approved the request.”
This should be included in the condition of the second notification to ensure it triggers correctly.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

hi Atul G,

Thank you for the suggestion....... where should I set the condition.... please guide me.

 

thank you

Hi @TMKAM 

 

Can you use Flow Designer instead of Workflow?
If yes, it will be much easier and mostly no-code for you.

You’ll need to build a script or use a condition in the notification to check if the previous approval has been approved—only then should it trigger. In Flow Designer, you can easily get that value, but I’m less familiar with how to do it in Workflow.

It’s a bit tricky, but you can search on the community for similar use cases—you’ll likely find a solution there.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Hi Atul,

if I use the flow designer im not sure how to add the below scripts into the email body?

 

scripts

Details about this requested product can be reviewed <a href='https://<mail_script>template.print(gs.getProperty('instance_name'));</mail_script>.service-now.com/serviceportal?id=bbraun_sc_request&table=sc_req_item&sys_id=${current.sysapproval.sys_id}&view=sp}'>here</a>.</b>
 
<b>Click here to respond:</b>
<a href='https://<mail_script>template.print(gs.getProperty('instance_name'));</mail_script>.service-now.com/serviceportal?view=sp&id=bnform&table=sysapproval_approver&sys_id=${sys_id}&sysparm_approval_state=approved'>Approve</a> or  <a href='https://<mail_script>template.print(gs.getProperty('instance_name'));</mail_script>.service-now.com/serviceportal?view=sp&id=bnform&table=sysapproval_approver&sys_id=${sys_id}&sysparm_approval_state=rejected'>Reject</a>.
 
<i>If you are using a <b>mobile device</b> please use the following links: </i><a href='https://<mail_script>template.print(gs.getProperty('instance_name'));</mail_script>.service-now.com/shop/mobile_approval.do?sysparm_requested_item=${current.sysapproval.sys_id}&sysparm_approval_state=approved'>Approve</a> or  <a href='https://<mail_script>template.print(gs.getProperty('instance_name'));</mail_script>.service-now.com/shop/mobile_approval.do?sysparm_requested_item=${current.sysapproval.sys_id}&sysparm_approval_state=rejected'>Reject</a>.