- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 02:57 AM
Dear all experts.
I'm trying to make a SCTASK notify Assessor of the assigned group. If i understand correctly from all community posts, i need to create a business rule which will insert a event that triggers a table list of recipient referrence to Groups.
Assessor table (Reference to Groups)
However, how do i use a gliderecord and add multiple users into Parm1 of events (pull out this Assessor table and reference to the assigned group)?
thanks for the help guys.. i'm really pulling out my hair on this issue.
Thanks!
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 03:24 AM
Hi Max,
Just glide the assessor table and create a list of users and then trigger the event like this.
ensure the right table name, sysid, eventname etc below.
var userList = [];
var grSysUserGrmember = new GlideRecord('assessor table name');
grSysUserGrmember.addEncodedQuery("group=477a05d153013010b846ddeeff7b1225"); //sysid of the group
grSysUserGrmember.query();
while (grSysUserGrmember.next()) {
userList.push(grSysUserGrmember.sys_id.toString());
}
gs.eventQueue("event.name", current, userList, parm2);
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 03:13 AM
Hi,
Sorry it's not clear.
Can you explain in detail?
what BR or script did you start?
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
05-10-2022 03:24 AM
Hi Max,
Just glide the assessor table and create a list of users and then trigger the event like this.
ensure the right table name, sysid, eventname etc below.
var userList = [];
var grSysUserGrmember = new GlideRecord('assessor table name');
grSysUserGrmember.addEncodedQuery("group=477a05d153013010b846ddeeff7b1225"); //sysid of the group
grSysUserGrmember.query();
while (grSysUserGrmember.next()) {
userList.push(grSysUserGrmember.sys_id.toString());
}
gs.eventQueue("event.name", current, userList, parm2);
Thanks