Hello,
My next task is to recreate a report based on new schema and data sources. I can see in measures of legacy report, that basically what developer did is :
Create one measure like
NotBlank = VAR num=CALCULATE(COUNTROWS('Table'),'Table'[Column]<>blank()) RETURN IF(num<>blank(),num,0)
Blank = VAR num=CALCULATE(COUNTROWS('Table'),'Table'[Column]=blank()) RETURN IF(num<>blank(),num,0)
Similary to count just DISTINCTCOUNTNOBLANK
Is there any better approach? Like establish that in PQ with either 0 and 1 or get the datasource with CASE or how? The drawback of SQL would be that they often count calculated columns, so I guess its not available in SQL/PQ unless I create it there.
These NotBlank and Blank are referenced in several other measures so I can't get them as variables, not convienient I guess
Thank you for your input and suggestions