Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!
Hello,
I have a problem that can be summed up like this:
I have a "Item" table and a "Sales line" table, with a many to one relationship based on Item ID (each Item has zero to many Sales line . Each sales line is for one Item).
I want to have a simple True/False column (not a measure) in my Item table to know if there is at least one Sales line with this Item (ignoring all filters, I just want to know if the Item was bought at some point) and use this in a slicer and as a dimension on charts.
It seems the "Related" function in my Item tables does not work, since it is a many-to-one relationship.
The only solution I see is in powerquery and require to do a distinct load and a left join, it seems heavy for a simple need.
Solved! Go to Solution.
@Anonymous , You can try a new column like
new column Flag =
var _1 = countx(relatedtable(Sales), sales[value]) +0
return
if(_1 >0,1 ,0)
refer 4 ways to copy data from one table to another
https://www.youtube.com/watch?v=Wu1mWxR23jU
https://www.youtube.com/watch?v=czNHt7UXIe8
Or measure count(sales[value]) +0 , should also work with me item
@Anonymous , You can try a new column like
new column Flag =
var _1 = countx(relatedtable(Sales), sales[value]) +0
return
if(_1 >0,1 ,0)
refer 4 ways to copy data from one table to another
https://www.youtube.com/watch?v=Wu1mWxR23jU
https://www.youtube.com/watch?v=czNHt7UXIe8
Or measure count(sales[value]) +0 , should also work with me item
The Power BI Data Visualization World Championships is back! It's time to submit your entry.
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 66 | |
| 44 | |
| 34 | |
| 26 | |
| 23 |
| User | Count |
|---|---|
| 137 | |
| 118 | |
| 58 | |
| 40 | |
| 35 |