Forum Discussion
Keeping null values in aggregation table
- Anonymous6 years ago
Hi Anonymous
I build the same table as yours to have a test.
Just like mwegener replied before you when you summarize ,you donāt need to add the BlankCommitFlag.
I build Measure to achieve your goal.
'AGG_REsource Request = VAR _MAXDH = MAXX ( FILTER ( ALL ( 'Table' ), 'Table'[Project NameID] = MAX ( 'Table'[Project NameID] ) ), 'Table'[Demand Hrs] ) VAR _MAXGH = MAXX ( FILTER ( ALL ( 'Table' ), 'Table'[Project NameID] = MAX ( 'Table'[Project NameID] ) ), 'Table'[Gap Hours] ) VAR _MAXCS = MAXX ( FILTER ( ALL ( 'Table' ), 'Table'[Project NameID] = MAX ( 'Table'[Project NameID] ) ), 'Table'[Commit Hrs] ) RETURN SUMMARIZE ( 'Table', [WorkCategoryValue], [Project NameID], 'Table'[ResourceRoleValue], 'Table'[ResourceNameId], 'Table'[TaskDetail], 'Table'[Date], "Demand Hrs", _MAXDH, "Gap Hours", _MAXGH, "Commit Hrs", _MAXCS )Result:
You can download the pbix file from this link: Keeping null values in aggregation table
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Rico Zhou
mwegener,
I first added the following column to the source data set to identify null values in the data set (I realize that null values are replaced by 0 values in aggregation tables):
BlankCommitFlag = IF(ISBLANK([Commit Hours]), "Y", "N"
Then in the Data View, Modelling > Create Table
'AGG_REsource Request = SUMMARIZE('FACT_ResourceRequestList',[WorkCategoryValue],[ProjectNameId],[Tier34OrgId],' etc. to build out the aggregated table.
I hope that helps,
ixdutt
Hi Anonymous
do not include the column BlankCommitFlag in your SUMMARIZE