Forum Discussion
Roland74
Helper I
1 year agoUSERELATIONSHIP and FILTER
Hi all, Needs some help, because i don't know why the next formula doesn't work. I've got a table with the next result: When i count the rows with reason PRJ_REISWW with the next formula ...
- 1 year ago
Don't filter entire tables, just filter the columns you need. You can use
Test_ROWS_High = CALCULATE ( COUNTROWS ( factPostedHourLine ), USERELATIONSHIP ( factPostedHourLine[WorkingDateID], 'Date'[DateID] ), Reason[ReasonCode] = "PRJ_REISWW", factPostedHourLine[Hours_Working_Date] > 0.50 )For detailed explanations of why its not working search https://www.sqlbi.com for "expanded tables".
johnt75
Super User
1 year agoDon't filter entire tables, just filter the columns you need. You can use
Test_ROWS_High =
CALCULATE (
COUNTROWS ( factPostedHourLine ),
USERELATIONSHIP ( factPostedHourLine[WorkingDateID], 'Date'[DateID] ),
Reason[ReasonCode] = "PRJ_REISWW",
factPostedHourLine[Hours_Working_Date] > 0.50
)
For detailed explanations of why its not working search https://www.sqlbi.com for "expanded tables".
Roland74
Helper I
1 year agoHi johnt75, This works, thanx.
Don't know why (yet), but i found the article and wil 'deep dive' in it 😆