Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hi,
I have Client, Period and Hours column. Need to calculate Net change and %Growth columns in power BI
Please help in achieving this.
Hi @Vaibhav3008 ,
Can you please try the following?
Net change =
IF(
SELECTEDVALUE( 'Table'[Client] ) =
CALCULATE(
MIN( 'Table'[Client] ),
OFFSET(
-1,
ORDERBY( 'Table'[Client], ASC, 'Table'[Period], ASC )
)
),
CALCULATE(
MIN( 'Table'[Hours] ) -
CALCULATE(
MIN( 'Table'[Hours] ),
OFFSET(
-1,
ORDERBY('Table'[Client], ASC, 'Table'[Period], ASC)
)
)
)
)
% Growth =
DIVIDE(
[Net change],
CALCULATE(
MIN( 'Table'[Hours] ),
OFFSET(
-1,
ORDERBY( 'Table'[Client], ASC, 'Table'[Period], ASC )
)
)
)
Result:
If I answered your question, please mark my post as a solution.
Best,
Thanks for the reply,
I applied it to my table and it says : Parameter is not the correct type
Can you please help resolve it
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
26 | |
20 | |
19 | |
14 | |
13 |
User | Count |
---|---|
43 | |
36 | |
24 | |
24 | |
22 |