Forum Discussion
"Group By" when you have more than one criteria in the column
- Nov 01, 2022
mrw2828 you can create multiple Views, each showing something different (pants or jackets or whatever) and then share the link to each View on a page, as for example clickable buttons, tiles, etc. E.g. one button named 'Pants', another named 'Jackets', under a text heading of 'Products'.
Here's a good starting point for creating views:
https://www.youtube.com/watch?v=8Y3CxqhO78M
Note: Whatever you 'Save as", will concatenate to your URL and be the 'name of the view' link you share with your users, so keep it short and succinct (I always abbreviate to reduce total characters), and then after saving, navigate to List/Library Settings, scroll down to where all the views are listed, click on that view you just saved, and then when it opens in the editing page, you can rename ('View Name" field) to make it a friendly name that will appear in the View menu, and also see the direct URL link (Web address of this view, ending in .aspx). Here you can edit the details of the view, too, in the classic experience. Essentially, you are making the URL different to the Friendly name of each view, as the total number of characters in the URL can become problematic down the track, especially when/if item/filenames are lengthy.
E.g. I might save as "ChinMed" or even "CM", then go back and change the 'View Name' field to "Chinese Medicine", so my URL is shorter by using "ChinMed" or "CM" as the view reference within the URL, but users will instead see "Chinese Medicine" in the View menu. Users don't care what the URL says.
You could save as 'Pants' and then go back and change the 'View Name" field to 'Product: Pants'. Then repeat for Jackets, and however many Products you've got.
Also note the View menu sorts all views alphabetically by name, so bear that in mind when coming up with a naming convention for your Friendly View names. You might want all Products to list above all Vendors, instead of having Products interspersed with Vendors in the View Menu, in which case prefixing all Friendly names with "Product: ..." will sort all the Products above anything prefixed with "Vendor:..." in your View menu. (as P comes before V).
For a decent overview on working with Views:
https://learn.microsoft.com/en-us/microsoft-365/community/creating-useful-views-in-lists-libraries
If working with larger Lists/Libraries (>5000 items/files), you'll need to consider the view thresholds:
https://learn.microsoft.com/en-us/microsoft-365/community/large-lists-large-libraries-in-sharepoint
Following steps works for me when grouping the second columns.
Once you have selected the types of groups you required, select show groupings by default as Expanded.
on your list view, you will first need to collapse all items. This will initially show only 4 items, once all items are loaded you can use expand on the group to see details.