Prevent Duplicate case creation which is created by Inbound Action
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-11-2023 10:37 AM - edited ‎08-11-2023 10:51 AM
Hi,
I have an Inbound action created, through which an offboarding Lifecycle case is being created. I want to prevent duplicate case creation if a case already exists for that leaver(subject_person). Any suggestions on how we can do this?
Thanks in advance.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2023 09:45 AM
Hi @Gayatrin ,
in your inbound action script, get leaver name(using email subject may be using split function and glide the offboarding Lifecycle case table with leaver name, if exist abort the creation using current.setAbortAction(true);
Thank you,
Hemanth
Certified Technical Architect (CTA), ServiceNow MVP 2024, 2025
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2023 10:51 PM
Hi @Hemanth M1,
Thanks for your response. I have the below code which is included in Inbound Action. when an email is received from outlook, the target is empty case is not being created even though the leaver doesn't have the case created before.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-13-2023 02:57 AM
Hi @Gayatrin ,
Couple of things to verify
1) Open the received email and under the email logs related list check whats the status of this inbound action did it run or skipped, if skipped check the reason
2) check in the same logs if any other inbound action is executing
May I know the else part of the script, how r u creating the case and the inbound action condition
Thank you,
Hemanth
Certified Technical Architect (CTA), ServiceNow MVP 2024, 2025
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-13-2023 08:22 PM - edited ‎08-14-2023 10:17 PM
Hi @Hemanth M1 ,
There are two logs related to this:
1.General : did not create or update sn_hr_core_case using current
2.Stop processing detected after executing script: General
Any other inbound is not executing.
Thanks