Get Free Trial

monthly growth measures

Answered
Gabriel Todeschini asked on December 30, 2020
Hello, I need to dynamically display a "Monthly Growth" field. I found an example in the documentation that shows how to do with two different fields, but in this case they are equal fields from different months, and it will always be comparing the CURRENT MONTH (sum ("Value")) with the PREVIOUS MONTH, there would be some way to specify the previous month?

5 answers

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster December 31, 2020

Hello,
 
Thank you for reaching out to us.
 
If we understand correctly, you require to display the difference of values between a previous and current month.
In this case, we suggest checking out the differenceofrow and differenceofcolumn aggregations.
 
Please see the following JSFiddle for reference: https://jsfiddle.net/flexmonster/Letf1anx/.
It demonstrates how to retrieve the difference in price between the previous and the current month.
 
We hope it works for you.
 
Regards,
Illia

Public
Gabriel Todeschini January 4, 2021

Sorry, could you analyze what is wrong with my code? I tried to reproduce this example but it doesn’t run the “differenceofrow”

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster January 5, 2021

Hello,
 
Thank you for your feedback.
 
Please note that the differenceofrow aggregation was introduced in version 2.8.7 of the component. Older versions apply the sum aggregation instead.
Please make sure the later version of the component is used in your case. To check the current version, focus on the component instance (for example, click on the grid) and use the following shortcut: “ctrl+alt+i”.
 
If older version is used in your project, we suggest updating to the latest version. Please see our updating guide for the reference.
 
We hope it helps.
Please contact us in case other questions arise.
 
Regards,
Illia

Public
Gabriel Todeschini January 5, 2021

Hello Illia, thank you, i belive it will work. How do I proceed with this message that appeared when I updated?

Attachments:
screenshot05.png

Public
Tetiana Tetiana Flexmonster January 6, 2021

Hi Gabriel,
Thank you for your request.
The answer was provided via email.
Kind regards,
Tetiana

Please login or Register to Submit Answer