GroupBy to print Survey Results

Brian Lancaster
Tera Sage

I'm working on a script for a notification. This will fire automatically every Monday to show the previous weeks survey results. This notification will fire for each assignment group. I'm trying to get it to list the assigned to person of the incident that the survey was taken on then the incident number etc. along with the results of they survey questions. Then go on and print the next incident number of survey results for that assigned to person. Example screenshot below. This screenshot show 2 incidents under the assigned to person but the second one that is highlighted belongs to a different assignee.

BrianLancaster_0-1745421058108.png

 

I got the format working the way I want it but groupBy is ignored in GlideRecord so sometime I get an incident for one assignee show under a different assignees name. With GlideAggregate I can group by but it only allows me to get the value of what I grouped by to print. Is there any other options script wise were I can group by and get values for all fields?

1 ACCEPTED SOLUTION

Brian Lancaster
Tera Sage

Figured it out. The group by was working I just needed to add an order by assigned to.

View solution in original post

1 REPLY 1

Brian Lancaster
Tera Sage

Figured it out. The group by was working I just needed to add an order by assigned to.