Forum Discussion
VANI_YN_80
5 years agoRegular Visitor
DAX formula Help
Hi Everyone, I have this Raw data and i want to calculate a new column called as PPC. The Formula for PPC is APP 2021 - APP2020 *Quantity posted 2021. could yop please help me with the formu...
- 5 years ago
Hi VANI_YN_80
Based on your data, you can create measures to get the result.
total qty 2020 = SUM('Table'[Quantity posted in 2020]) gross value total 2020 = SUM('Table'[Gross value in local currency 2020]) APP 2020 = DIVIDE([gross value total 2020],[total qty 2020]) total qty 2021 = SUM('Table'[Quantity posted in 2021]) gross value total 2021 = SUM('Table'[Gross value in local currency 2021]) APP 2021 = DIVIDE([gross value total 2021],[total qty 2021]) PPC = [APP 2020] - [APP 2021] * [total qty 2021]If you want to get the result with a single measure instead of above meaures, you can use below one.
PPC 2 = DIVIDE(SUM('Table'[Gross value in local currency 2020]),SUM('Table'[Quantity posted in 2020])) - DIVIDE(SUM('Table'[Gross value in local currency 2021]),SUM('Table'[Quantity posted in 2021])) * SUM('Table'[Quantity posted in 2021])Regards,
Community Support Team _ Jing
If this post helps, please Accept it as a solution to help other members find it.
VANI_YN_80
5 years agoRegular Visitor
Hi Samarth_18
thanks for the reply.
Below is the one drive link. Please check if you can access it.
Regards
Vani
Anonymous
5 years agoNot applicable