Solved

# Help with RUNSUM

• New Participant

Hello!

I’m heaving some problems to do a RUMSUN without an atribute Date. I’m trying to do it with an atribute of mt products:

Basicaly i’m trying to an RUNSUM of that valeu for each product. The only way i could make summing all of then, but i need sum for after another.

I know i can make this if the accumulate direct on the report but i need to make the metric.

Does anyone knows how to code this? i tried many ways but none works.

Thank you!

icon

Best answer by Moises Morales 25 October 2022, 03:37

View original

### 13 replies

Userlevel 3

Hi Thiago,

Running total metrics can be broken down by two or more date attributes from the same date dimension. Non-date attributes are not supported. This is mentioned in our documentation here: Running Totals for Core Functions - Gooddata Free. It is however possible, to right click an attribute so you will have the option to use the Runsum function even with a non date attribute.

Best regards,

-Moises

So non date atributos is not possible? I work doing this way that you mention, but i needed the metric tô then make a percentenge and use in a pareto relativo of 80/20. Basicaly Thats why i need to make a runsum and acumulate the valeus of my sell by products.

There is no way to be done?

Userlevel 3

I'm terribly sorry to be the bearer of bad news, but there is no workaround that would allow this. The RUNSUM can only be used with "Dates" and not other attributes.

So non date atributos is not possible? I work doing this way that you mention, but i needed the metric tô then make a percentenge and use in a pareto relativo of 80/20. Basicaly Thats why i need to make a runsum and acumulate the valeus of my sell by products.

There is no way to be done?

Tiago, bom dia!

Tudo bem?

Estou com um problema muito parecido com o seu, e gostaria de saber se conseguiu alguma alternativa para fazer este cálculo?

Userlevel 3

Hi Cristovan,

Please note that at this time, our Community forum is offered exclusively in English. While we understand and value the importance of catering to diverse linguistic needs, we have limited our support to ensure the highest level of service quality and efficiency. Having said that, please feel free to open a new thread or reply here in English in case further assistance is needed from GoodData staff.

-Moises

Hi Cristovan,

Please note that at this time, our Community forum is offered exclusively in English. While we understand and value the importance of catering to diverse linguistic needs, we have limited our support to ensure the highest level of service quality and efficiency. Having said that, please feel free to open a new thread or reply here in English in case further assistance is needed from GoodData staff.

-Moises

Sorry about that, I'll correct the question.

So non date atributos is not possible? I work doing this way that you mention, but i needed the metric tô then make a percentenge and use in a pareto relativo of 80/20. Basicaly Thats why i need to make a runsum and acumulate the valeus of my sell by products.

There is no way to be done?

Thiago, good morning!

All good?

I have a problem very similar to yours, and I would like to know if you have found an alternative to do this calculation?

Userlevel 3

No problem. Could you please share your metric and an example of the final result? Thanks.

No problem. Could you please share your metric and an example of the final result? Thanks.

I'm trying to create a Customer ABC Curve report, where I have the %REP metric that demonstrates the representativeness of the weight sold over the total, I need to create a "%ACUMULADO" metric where I make the accumulated sum of the %REP metric.
Currently my "%ACUMULADO" metric has the following formula: "SELECT RUNSUM(SUM(REPRESENTATIVIDADE))" but the "RUNSUM" does not show the expected result.

Userlevel 3

I see you are working with our Pixel Perfect UI, in that case you can simply right click the %REP column and get the running sum of it as shown below. You can also rename the new column.

I see you are working with our Pixel Perfect UI, in that case you can simply right click the %REP column and get the running sum of it as shown below. You can also rename the new column.

I tried this way, but I need the value of the column "%ACUMULADO" as a metric to be able to use this value as an ABC classification, for example "if %ACUMULADO<= 20 then A".
Is there any way to use the column value in the way you showed me within another metric?

Userlevel 3

Thanks for clarifying. Unfortunately I must repeat the same answer provided previously. It's unfortunately not possible to use the runsum metric on a non date attribute, it's only possible if you have a table and you right click on the attribute, This is because a running sum can only be calculated along a date attribute (e.g. running sum of revenue to create a MTD). I recommend creating the new metric based on this.

Thanks for clarifying. Unfortunately I must repeat the same answer provided previously. It's unfortunately not possible to use the runsum metric on a non date attribute, it's only possible if you have a table and you right click on the attribute, This is because a running sum can only be calculated along a date attribute (e.g. running sum of revenue to create a MTD). I recommend creating the new metric based on this.

OK no problem. Thanks a lot for the help.