Forum Discussion
Analyze in Excel Null Values
Hi, PBILix
I am glad to help you.
You need to make sure that the TREATAS function handles null values correctly. You may need to adjust the filtering logic so that rows in Table A are included even if there is no corresponding row in Table B.
In SQL, you would normally use a LEFT JOIN to include all the rows in table A as well as the matching rows in table B. You can use ADDCOLLIN in DAX. You can use the ADDCOLUMNS and RELATED functions in DAX to simulate this behavior.
VAR __DS0Core =
ADDCOLUMNS(
'A',
"B_Column", RELATED('B'[B])
)
Since you mentioned that the model uses one-to-many bi-directional filtering, make sure that the relationship settings are configured correctly. Sometimes changing the direction of cross-filtering to unidirectional can help with this situation.
If possible, check the data model to make sure the relationships and data types are properly defined. Sometimes, null value issues can stem from data type mismatches or incorrectly defined relationships.
I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Fen Ling,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.