The CreatorCon Call for Content is officially open! Get started here.

Is it possible to group by multiple columns in Module

Dinh Nguyen
Kilo Sage

Hello everyone,

I'm wondering if it's possible to group 2 fields in a module.

I can't find any documentation that mentions whether it is possible to group by multiple columns.

I have created a Module and set it as shown below, but it doesn't work:

Arguments: problem_list.do?sysparm_query=GROUPBYstate^GROUPBYpriority&sysparm_first_row=1&sysparm_view=

DinhNguyen_0-1743739498400.png

And this is result, My handling can only group field state:

DinhNguyen_1-1743739641477.png

I don't know if I'm handling it wrong or if this is a ServiceNow limitation, if it is a limitation is there any documentation about this. Please someone help me.

Thank you so much.

 

 

2 ACCEPTED SOLUTIONS

Ankur Bawiskar
Tera Patron
Tera Patron

@Dinh Nguyen 

not possible.

you can only group by 1 and that's how the OOB behavior is when you try to do group by manually on list

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

Rohit  Singh
Mega Sage

Hi @Dinh Nguyen ,

 

You cannot group by two columns in the list view. However you can achieve it using a report.

 

Refer the link for creating Report : Multi-tiered "group-by" list report 

 

If my response helped, please hit the Thumb Icon and accept the solution so that it benefits future readers.

 

Regards,
Rohit

View solution in original post

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

@Dinh Nguyen 

not possible.

you can only group by 1 and that's how the OOB behavior is when you try to do group by manually on list

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Rohit  Singh
Mega Sage

Hi @Dinh Nguyen ,

 

You cannot group by two columns in the list view. However you can achieve it using a report.

 

Refer the link for creating Report : Multi-tiered "group-by" list report 

 

If my response helped, please hit the Thumb Icon and accept the solution so that it benefits future readers.

 

Regards,
Rohit