Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Bharathpowerbi
New Member

Regarding hash one value dax function

Regarding hash one Value dax function it supports cross filter right it is not working.

Created hashonevalue on segment column trying to filter on country column but not filtering.

1000090527.jpg

1 ACCEPTED SOLUTION
DataNinja777
Super User
Super User

Hi @Bharathpowerbi ,

 

The reason your hashonevalue measure isn't returning a result when filtering by Country is because of how HASONEVALUE(financials[Segment]) works. Your formula:

hashonevalue = IF(HASONEVALUE(financials[Segment]), SUM(financials[Profit]), BLANK())

only returns the profit if exactly one segment is selected. When you select France in the Country slicer, it may still include multiple segments in the data, so HASONEVALUE returns false, and the measure shows blank. This is expected behavior, not a cross-filtering issue.

To confirm how many segments are active under the current filters, you can add:

Selected Segment Count = DISTINCTCOUNT(financials[Segment])

If this count is greater than one, your original measure will remain blank. The measure is working as designed, but the result depends entirely on the data context created by your slicers.

 

Best regards,

View solution in original post

5 REPLIES 5
v-sdhruv
Community Support
Community Support

Hi @Bharathpowerbi ,
Just wanted to check if you had the opportunity to review the suggestions provided?
If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank You

v-sdhruv
Community Support
Community Support

Hi @Bharathpowerbi ,
Just wanted to check if you had the opportunity to review the suggestions provided?
If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank You

v-sdhruv
Community Support
Community Support

Hi @Bharathpowerbi ,
Just wanted to check if you had the opportunity to review the suggestions provided?
If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank You

DataNinja777
Super User
Super User

Hi @Bharathpowerbi ,

 

The reason your hashonevalue measure isn't returning a result when filtering by Country is because of how HASONEVALUE(financials[Segment]) works. Your formula:

hashonevalue = IF(HASONEVALUE(financials[Segment]), SUM(financials[Profit]), BLANK())

only returns the profit if exactly one segment is selected. When you select France in the Country slicer, it may still include multiple segments in the data, so HASONEVALUE returns false, and the measure shows blank. This is expected behavior, not a cross-filtering issue.

To confirm how many segments are active under the current filters, you can add:

Selected Segment Count = DISTINCTCOUNT(financials[Segment])

If this count is greater than one, your original measure will remain blank. The measure is working as designed, but the result depends entirely on the data context created by your slicers.

 

Best regards,

Sourav_M
Frequent Visitor

Hi @Bharathpowerbi  - Can you please elaborate what exactly you are looking for and what is that iscrossfiltered measure, to analyse the problem statement.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.