Forum Discussion
Vinnie
Helper I
3 years agoCircular dependency in DAX column
Hi all, I need help with a DAX column. Originally the column worked just fine but when I added some extra logic I got an error (circular dependency). I am still trying to understand what a ci...
- 3 years ago
I fixed this issue by adjusting the DAX statement for the DAX column DateMovedOutWorkingStock.
I replaced
var dateinworkingstock = calculate(selectedvalue(File[DateInWorkingStock]))by:
var dateinworkingstock = LOOKUPVALUE(File[DateInWorkingStock], File[ID], File[ID])
Vinnie
Helper I
3 years agoI do think it might have to do with a calculated table I have in my datamodel.
The exact error of the circular dependency mentions this table as well, as the 'File' table.
This calculated column is a seperate table and the DAX code is as follows:
Working stock =
GENERATE(ALLNOBLANKROW(‘Calender Workingstock’[Date]),
CALCULATETABLE(
var measuredate = SELECTEDVALUE(‘Calender Workingstock’[Date])
var temptable =
filter(File, File[DateInWorkingStock] <= meetdatum &&
(File[DateMovedOutWorkingStock] > meetdatum || isblank(File[DateMovedOutWorkingStock])))
return selectcolumns(temptabel, "ID File", File[id File])
)
)
The DAX column DateMovedOutWorkingStock does not give an error when I remove this DAX table. But of course that is not a solution.