How to set value to reference field using sys_id
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-26-2016 02:37 AM
Hi all,
I am having sys_id of company name and i want to set that company name to reference field using sys_id.So how to do it?Please anyone can tell?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2016 07:04 AM
I will try c) to check if my id is correct, thanks for the hint.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2016 08:12 AM
Indeed. Perhaps try hardcoding the sys_id of an incident on your code just for troubleshooting purposes.
Thanks,
Berny
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2016 08:12 AM
Hi Wolfgang,
If you're trying to create a new record try using a .insert() instead of .update();
Thanks,
Berny
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-20-2017 03:08 AM
Hi,
Do you have any idea how set values to section fields?
i want to set value for assigment group -> assignment group is under "assignment" section in incident form.
by using code its not working.
g_form.setValue('assignment_group', "Service Now");
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-20-2017 03:15 AM
Hi Sowmyab,
If the assignment group is reference field try assigning sys_id of group.
g_form.setValue('assignment_group','sys_id');