- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-14-2022 04:01 PM
Hi, I have a scenario where if I get any value that doesn't exist in choice list (target table field is a choice list where label and field = ABC). The issue is how to set the target field value to the default value as 'ABC'. Please help me with this. Thanks.
If(source.u_company_name == 'ABC' || source.u_company_name == 'DEF'){
ignore =false;
} else {
target.u_company_name = 'ABC'; // not able to get this set
ignore =true;
}
Solved! Go to Solution.
- Labels:
-
Cost Management (ITSM)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-15-2022 08:31 AM
Glad to know that my script worked.
Thank you for marking my response as helpful.
If my response helped please mark it correct and close the thread so that it benefits future readers.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-15-2022 07:47 AM
Hi Ankur, able to get this set when I removed 'ignore=true' from else condition. Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-15-2022 08:31 AM
Glad to know that my script worked.
Thank you for marking my response as helpful.
If my response helped please mark it correct and close the thread so that it benefits future readers.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader