Subitems Subtotal

Can you sum a column in the sibitems and have the value populate in the Parent row

Hello @Jeffrey_Sykier

Looking at the figure you posted, it seems that you have one column representing a relationship, and the subitems within the row are actually part of another table. Is that correct?

If so, you can set a formula for “R1 Jobs Closed” like this: thisRow.Subitems.#Jobs Closed - Sum.Sum()
You can also add filters using the Filter() formula.

Sharing a dummy doc with your attempt would make it easier to assist you.

Let me know if this is what you’re trying to achieve.

Best Regards
Arnhold

1 Like

Ok I’m a little new to the world of CODA. I think i created the new DOC to share. I need to total the sub items but not have it affect the grand total at the bottom of the main table.

Hi Jeffrey,

I unfortunately do not have time to get into details on this, but I can give you some pointers.

Option 1: This would be easily resolved if sub-items were already implemented for grouping, but give it a try to group by the parent row, and summarise on the relevant column. That might work.

Option 2: Implement a new column, sub_totals, with the following formula:
If this is the lowest row in a sub-item hierarchy,
then copy the value from the jobs closed column
else sum the values in the sub_total column.

There is a beautiful example given by one of the community members in a post on how to implement the logic that I have written in English above. I had a quick look, but unfortunately was not able to find it.

It;s just a ramble,
Rambling Pete

Hi @Jeffrey_Sykier

From your doc, it seems that you are using the subitems feature. Unfortunately, there is no straightforward solution to summarize data from the subitems. This is one of the features I requested in the subitems feedback.

However, I see two possible ways to handle this:

  1. The easiest way is to set up an automation that updates the parent rows every time a subitem changes in the table. The downside of this approach is that the automation doesn’t run immediately. In my experience, it can take up to one minute to actually execute and update the doc.
  2. You can add another column that calculates the sum of the subitems. In the leaf subitems, you would manually input data in an editable column, and the sum would be displayed in the parent subitems in a calculated column. The downside is that you will have two columns, which may not be visually appealing and could be confusing for users.

You can try using this trick to speed up automation, but you will still need to press a button manually.

I impleted both options on your doc. Let me know if some of them is suficient or you.

Best regards
Arnhold

I had a feeling that what I was trying to do was out of the native capability of CODA and the subitem feature. The project I am working on that this is a part of is a quick one so not sure if I’ll spend the time to automate things at this point, but will take deeper look at what you dropped in on the the DOC. im sure ill be able to use that in another project. Appreciate you taking the time. I’ll figure something out.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.