I am trying to count the number of hotels in "Hotel Names" that have blank "Descriptions" in the table below. My current measures keep on counting repeated names as additional hotels. Please help.
Try
Blank = CALCULATE(DISTINCTCOUNTNOBLANK(Hotel[Hotel Name ]),not( ISBLANK(Hotel[Desc])))
You can try the below DAX
Hi @acohen-ih-corp ,
If you want to calculate the amount that have empty description completely, such as following situation:
If you do not want to count C, you can use the following measure:
Count = COUNTROWS ( FILTER ( ADDCOLUMNS ( SELECTCOLUMNS ( DISTINCT ( 'Hotel'[Name] ), "n", [Name] ), "MaxLength", MAXX ( FILTER ( ADDCOLUMNS ( 'Hotel', "DescriptionLength", LEN ( 'Hotel'[Description] ) ), [DescriptionLength] = [n] ), [DescriptionLength] ) ), [MaxLength] = 0 ) )
BTW, pbix as attached.
Best regards,
Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @acohen-ih-corp ,
How about the result after you follow the suggestions mentioned in my original post?Could you please provide more details about it If it doesn't meet your requirement?
Best regards,
Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
125 | |
81 | |
55 | |
53 | |
45 |