Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello!
I have a table that follows this structure:
| id | month | monthly price |
| 111 | 01/12/2023 | 3528,58 |
| 111 | 01/01/2024 | 3659,41 |
| 111 | 01/02/2024 | 4866,62 |
| 111 | 01/03/2024 | 6650,90 |
| 222 | 01/12/2023 | 1000,10 |
| 222 | 01/01/2024 | 2000,20 |
| 222 | 01/02/2024 | 3000,30 |
I want to create a new column that does the following calculation, by each different id:
(((monthly price / last December's monthly price) -1) *100) + 100
The expected result would be something like this:
| id | month | monthly price | new column |
| 111 | 01/12/2023 | 3528,58 | (value based on December 2022) |
| 111 | 01/01/2024 | 3659,41 | 103,7077 |
| 111 | 01/02/2024 | 4866,62 | 137,9201 |
| 111 | 01/03/2024 | 6650,90 | 188,4866 |
| 222 | 01/12/2023 | 1000,10 | (value based on December 2022) |
| 222 | 01/01/2024 | 2000,20 | 200 |
| 222 | 01/02/2024 | 3000,30 | 300 |
How can I make this new column?
Solved! Go to Solution.
@nok See PBIX attached below signature.
Column =
VAR __Min = MIN( 'Table'[month] )
VAR __id = [id]
VAR __LastDecember = DATE( YEAR( [month] ) - 1, 12, 1 )
VAR __LastDecValue = MAXX( FILTER( 'Table', [id] = __id && [month] = __LastDecember ), [monthly price] )
VAR __Result = IF( [month] = __Min, BLANK(), ( ( ( [monthly price] / __LastDecValue ) - 1 ) * 100 ) + 100 )
RETURN
__Result
@nok See PBIX attached below signature.
Column =
VAR __Min = MIN( 'Table'[month] )
VAR __id = [id]
VAR __LastDecember = DATE( YEAR( [month] ) - 1, 12, 1 )
VAR __LastDecValue = MAXX( FILTER( 'Table', [id] = __id && [month] = __LastDecember ), [monthly price] )
VAR __Result = IF( [month] = __Min, BLANK(), ( ( ( [monthly price] / __LastDecValue ) - 1 ) * 100 ) + 100 )
RETURN
__Result
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!