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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
chahineatallah
Helper III
Helper III

hasonevalue

hi everyone

 

am using hasonevalue, but i dont know why its not working, in my date filter context i should have 3 customers, so my hasonevalue should give blank, but when i expand the date then each customer ,his salary should be shown as filter context now only shows one customer , isnt? or am missing on something, as i put hasonevalue(customerid)

hasonevalue.png

1 ACCEPTED SOLUTION

i fixed it thanks, i used my solution, it worked after i restarted the pc

View solution in original post

4 REPLIES 4
v-cazheng-msft
Community Support
Community Support

Hi @chahineatallah,

 

May I know if you correct your table name used in the dax formula, will you get what you want?

total salary = IF(HASONEVALUE('fact table'[customer ID]),SUM(customer[salary]),"")

 

If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let me know. Thanks a lot!

 

Best Regards,

Community Support Team _ Caiyun

i fixed it thanks, i used my solution, it worked after i restarted the pc

@chahineatallah,

 

That's great! Thanks for your reply! 

 

Could you please share and mark your solution by Accept it as the solution to close this post and help others find it more quickly? Thanks in advance!

 

Best Regards,

Community Support Team _ Caiyun

vapid128
Solution Specialist
Solution Specialist

hasonevalue('fact table'[customer ID])

 

wrong table name

 

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.