Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Circular dependency error while calculating columns based on measure and previous column values

I am facing one circular dependency issue under following scenario.

 

My expectation:

(Next Value of [Column2]) = (Previous value of [Column2]) + Abs([Measure1] - (Current value of [Column1])

 

Where:

[Measure1] = [Measure2] / [Measure3]

[Measure2] = CALCULATE(SUM([Column2], FILTER('Query', 'Query'[sFilter] = "Yes")

[Measure3] = CALCULATE(COUNT([Total number of Rows]), 'Query'[sFilter] = "Yes")

 

The above use case is required as it as. However, when I frame the formula for these just like above, I get circular dependency issue.

Any help would be appreciated.

 

Thanks.

1 ACCEPTED SOLUTION
Anonymous
Not applicable

I think I solved the problem. And the solution again lies in transforming dependent measures into separate columns and then picking up the latest value from those columns being treated as measures. This is I guess by design since PBI treats most of the things in tabular format and hence mixing measures with columns needs special attention when they are computed based upon their initial values.

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , Not very clear with your formula's. Also a column can not use a measure .

 

Can you share sample data and sample output in a table format? Or a sample pbix after removing sensitive data.

 

also refer: https://www.sqlbi.com/articles/avoiding-circular-dependency-errors-in-dax/

Anonymous
Not applicable

I think I solved the problem. And the solution again lies in transforming dependent measures into separate columns and then picking up the latest value from those columns being treated as measures. This is I guess by design since PBI treats most of the things in tabular format and hence mixing measures with columns needs special attention when they are computed based upon their initial values.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors