Forum Discussion
Project status report based on subtasks status
- Anonymous4 years ago
Hi margheritamart ,
I created a sample pbix file(see attachment) for you, please check whether that is what you want. You can create a calculated column as below:
Column = VAR _pitemcount = CALCULATE ( DISTINCTCOUNT ( 'Items'[Item] ), FILTER ( ALLSELECTED ( 'Items' ), 'Items'[Project ID] = EARLIER ( 'Orders'[Project ID] ) ) ) VAR _statuscount = CALCULATE ( DISTINCTCOUNT ( 'Items'[Item] ), FILTER ( ALLSELECTED ( 'Items' ), 'Items'[Project ID] = EARLIER ( 'Orders'[Project ID] ) && 'Items'[Status] IN { "Delivered", "Invoiced" } ) ) RETURN IF ( _pitemcount = _statuscount && 'Orders'[Status] = "In progress", "complete project", 'Orders'[Status] )If the above one can't help you get the desired result, please provide some sample data in the table Items and Orders table and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.
How to upload PBI in Community
Best Regards
Hi margheritamart ,
I created a sample pbix file(see attachment) for you, please check whether that is what you want. You can create a calculated column as below:
Column =
VAR _pitemcount =
CALCULATE (
DISTINCTCOUNT ( 'Items'[Item] ),
FILTER (
ALLSELECTED ( 'Items' ),
'Items'[Project ID] = EARLIER ( 'Orders'[Project ID] )
)
)
VAR _statuscount =
CALCULATE (
DISTINCTCOUNT ( 'Items'[Item] ),
FILTER (
ALLSELECTED ( 'Items' ),
'Items'[Project ID] = EARLIER ( 'Orders'[Project ID] )
&& 'Items'[Status] IN { "Delivered", "Invoiced" }
)
)
RETURN
IF (
_pitemcount = _statuscount
&& 'Orders'[Status] = "In progress",
"complete project",
'Orders'[Status]
)
If the above one can't help you get the desired result, please provide some sample data in the table Items and Orders table and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.
How to upload PBI in Community
Best Regards