Forum Discussion
Utterly perplexed why I'm getting error messages when refreshing this model
- 1 month ago
Hi masplin
Please check the below points.
IncomeGroup[Min]/[Max] call the measures [Total Population] and [Av annual Net Income], which scan all of MSOA_Mapping including [Income Group]/[Income Tgt], which are built from Min/Max. That loop is what breaks the rebuild.Three quick edits fix it:
1. Add a plain column: MSOA Population = CALCULATE ( SUM ( 'Age by MSOA'[Population] ), 'Age by MSOA'[Year] = 2024 )
2. In Min and Max, replace the AVIncome VAR (drop the measures):
VAR AVIncome =
DIVIDE (
SUMX ( MSOA_Mapping, MSOA_Mapping[MSOA Population] * MSOA_Mapping[Net annual income after housing costs (£)] ),
SUMX ( MSOA_Mapping, MSOA_Mapping[MSOA Population] ),
BLANK ()
)
Keep the rest of Min/Max unchanged same result.
3. Set MSOA_Mapping[LA Name] → Property[LA_name] to single-direction (keep it Active).Note: never call a measure inside a calculated column on a table that measure scans.
Make those three changes and refresh sorted.
Thank you.
Hello again
I know that because, while trying to delete (not disable) all relationships, I got many error messages of circular reference between columns and tables. I had to delete a lot of calculated columns and, once those errors vanished and I could delete the last relationship, the refresh was successful.
Where can I upload the file successfully refreashed with the modified queries?
Best
If this helped, please consider giving kudos and mark as a solution
me in replies or I'll lose your thread
Want to check your DAX skills? Answer my biweekly DAX challenges on the kubisco Linkedin page
Consider voting this Power BI idea
Francesco Bergamaschi
MBA, M.Eng, M.Econ, Professor of BI
Hi. So seems like so odd issue with circular references for things built after the structure of the modle was built that dont actually show up as errors as long as relationship in place!!!! So i guess if i take your version and start adding back the relationships and calc columns I may locate where the circular ref is coming from?
Can i share a dropbox folder with you? I think i'd need oyur email address. Really appreciate you putting time into this
- FBergamaschi1 month agoSuper User
Yes please share with [email protected]
Please consider marking my answer as a solution once you double check
Thanks
- masplin1 month agoImpactful Individual
Hi I created a folder here Demographics
Still seems odd to have ciruclar references only after you try to remove the relationships!!!
- FBergamaschi1 month agoSuper User
Hello masplin
I uploaded the file. The problem was due to calculated columns and relationships (again, circular references).
If this helped, please consider giving kudos and mark as a solution
@me in replies or I'll lose your thread
Want to check your DAX skills? Answer my biweekly DAX challenges on the kubisco Linkedin page
Consider voting this Power BI idea
Francesco Bergamaschi
MBA, M.Eng, M.Econ, Professor of BI