Welcome to the Smartsheet Forum Archives
The posts in this forum are no longer monitored for accuracy and their content may no longer be current. If there's a discussion here that interests you and you'd like to find (or create) a more current version, please Visit the Current Forums.
how to count rows under a parent and sub parent(s)
I have a sheet that is grouped by product categories. Underneath that category are products, and within/under a product are projects that are active and/or planned. So imagine the structure of the sheet is:
Product category
Product A
Project A
Project B
Project C
Product B
Project A
Project B
I would like to display a count of both products and projects next to the product category, like this: Product category - 2 - 5
Can i do this? if yes how?
Thanks
Comments
-
Use the COUNT, SUM, and CHILDREN functions
I would create one column to get the count of children.
=COUNT(CHILDREN())
Another column to determine if the row is a parent and if so, get both the current rows value and the sum of the children
Something like this
=IF(Counter23 > 0, "Product Category - " + Counter23 + " - " + SUM(CHILDREN(Counter23)), "")
where Counter is my column name and row 23 is where the formula is.
If you have more than 2 tiers, it is more difficult, but still possible.
Craig
-
Thank you. I will try this.
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 63.9K Get Help
- 410 Global Discussions
- 219 Industry Talk
- 457 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 136 Just for fun
- 57 Community Job Board
- 459 Show & Tell
- 31 Member Spotlight
- 1 SmartStories
- 298 Events
- 37 Webinars
- 7.3K Forum Archives