Subtotal by Specific Selection

Are you able to subtotal based on selected lines? I am wanting to subtotal based on what our Product Code starts with. If it starts with 101… I would like it to subtotal. If there is not a standard way to achieve this, is there potentially an admin thing that could be done to make this happen?

See screenshot.

Hello! Great question, and yes, you can get a subtotal in the grid by highlighting the cells you want it to total, and the bottom of the screen will have an Average/Count/Sum display.


Hope that helps!

@lbullard90 - If you’re looking for quick numbers, then Erin’s response is definitely the way to go! If you wanted to subtotal multiple groups, say on the first 3 digits of the Product Code, and compare them side by side, then yes, there is an admin thing that can be done to make this happen.

In Database Designer, an admin could add an Expression transform column basically pulling the first 3 digits of the Product Code column, then use the new column to create a sub-dimension. This would be done with a simple SQL statement to find LEFT([KLINGER_CODE], 3). For example, the sub-dimension might be called “KLINGER Code Group”, and the output would be lines of:
101
102
103
etc.

The corresponding data would flow next to those groups that were created. You could even use the Nested Table mode to have things grouped up by the KLINGER Code Group, then you could drop it into the specific KLINGER Codes from there.