Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi everyone, trying to add a new column to a table and populate it with yes or no based on the data from the selected column.
There are many duplicates in the name column and if any of the names have a yes in the selected column I want a yes to be populated in all cells in the new column.
For examble Apple appears 3 times in name column with 2 yes and 1 no in selected column, in the new column I want to see all entries for apple say yes.
Grape appears 2 times in name column with 0 yes and 2 no in selected column, in the new column I want to see all entries for grape say no.
Name | Selected | New column |
Apple | Yes | |
Banana | Yes | |
Grape | No | |
Apple | No | |
Apple | Yes | |
Banana | No | |
Grape | No |
Solved! Go to Solution.
@Anonymous
is this what you want?
Column = if(CALCULATE(COUNTROWS(Table2),FILTER('Table2',Table2[Name]=EARLIER(Table2[Name])&&Table2[Selected]="Yes"))>0,"Yes","No")
Proud to be a Super User!
@Anonymous
is this what you want?
Column = if(CALCULATE(COUNTROWS(Table2),FILTER('Table2',Table2[Name]=EARLIER(Table2[Name])&&Table2[Selected]="Yes"))>0,"Yes","No")
Proud to be a Super User!
Hi ryan_mayu, thank you so much for your help this is exactly what I wanted!!
I don't understan the double && but it works 🙂
@Anonymous
you are welcome, && is the same as AND in excel and || is the same as OR in excel.
Proud to be a Super User!
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
106 | |
94 | |
77 | |
65 | |
53 |
User | Count |
---|---|
147 | |
106 | |
104 | |
87 | |
61 |