Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin 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.
Hi,
I have been asked to compare if a specific id is present across a number of years - yes and no means they are present, blank means they are not present.
Below is an example of what i need - the data is within one table
Essentially i need the result in column e, stating whether the ID is present within each year column "yes", "no", and ignoring blanks.
Any help or additional questions needed please let me know
Kind regards,
Callum
| Result | |||||
| A | b | c | d | e | |
| ID | 2019 | 2020 | 2021 | in 2021 and 2020 and 2019? | |
| 000113 | No | Yes | Yes | ||
| 000114 | Yes | No | |||
| 000115 | Yes | No | |||
| 000116 | No | Yes | Yes | ||
| 000117 | Yes | No |
Hi @SuperCal99 ,
You can create a calculated column using the IF condition as mentioned below:
e = IF(AND(AND(b=" ",c="No"),d="Yes"),"Yes",
IF(AND(AND(b=" ",c=" "),d="Yes"),"No",
IF(AND(AND(b=" ",c=" "),d="Yes"),"No",
IF(AND(AND(b="No ",c=" "),d="Yes"),"Yes",
IF(AND(AND(b=" ",c="Yes"),d="No"),"No",blank())))))
I hope this helps!
Did I answer your question? Mark my post as a solution!
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 3 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 8 | |
| 7 | |
| 7 |