This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowThe Fabric community is upgrading! Read all of the details including the timeline and what you can expect. Learn more
Solved! Go to Solution.
As its a one-to-many you would need to use RELATEDTABLE, e.g.
Project Active, No Achievement Updates in 30 Days =
CALCULATE (
COUNTROWS ( 'Projects Data2' ),
FILTER (
'Projects Data2',
VAR MaxModifiedDate =
MAXX ( RELATEDTABLE ( 'Projects UA2' ), 'Projects UA2'[modified] )
RETURN
MaxModifiedDate
< TODAY () - 30
&& ISBLANK ( RELATED ( 'Projects PA2'[AchievementDate] ) )
&& 'Projects Data2'[projectstatus] = "Active"
&& NOT ISBLANK ( 'Projects Data2'[projectnumber] )
)
)
Thank you!
It comes back with " The column 'Projects UA2[modified]' either doesn't exist or doesn't have a relationship to any table available in the current context."
When I type in the name, it is not showing me all the tables in the workspace, only one that is an excel upload.
What is the relationship between 'Projects UA2' and 'Projects Data2' ?
The relationships between Projects UA2 and Projects Data2 is below:
As its a one-to-many you would need to use RELATEDTABLE, e.g.
Project Active, No Achievement Updates in 30 Days =
CALCULATE (
COUNTROWS ( 'Projects Data2' ),
FILTER (
'Projects Data2',
VAR MaxModifiedDate =
MAXX ( RELATEDTABLE ( 'Projects UA2' ), 'Projects UA2'[modified] )
RETURN
MaxModifiedDate
< TODAY () - 30
&& ISBLANK ( RELATED ( 'Projects PA2'[AchievementDate] ) )
&& 'Projects Data2'[projectstatus] = "Active"
&& NOT ISBLANK ( 'Projects Data2'[projectnumber] )
)
)
Because you're trying to access columns from a different table you need to use the RELATED function. Also, you can combine all the filter conditions into one,
Project Active, No Achievement Updates in 30 Days =
CALCULATE (
COUNTROWS ( 'Projects Data2' ),
FILTER (
'Projects Data2',
RELATED ( 'Projects UA2'[modified] )
< TODAY () - 30
&& ISBLANK ( RELATED ( 'Projects PA2'[AchievementDate] ) )
&& 'Projects Data2'[projectstatus] = "Active"
&& NOT ISBLANK ( 'Projects Data2'[projectnumber] )
)
)
Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.
| User | Count |
|---|---|
| 24 | |
| 22 | |
| 20 | |
| 18 | |
| 14 |
| User | Count |
|---|---|
| 44 | |
| 36 | |
| 23 | |
| 20 | |
| 20 |