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

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.

Reply
moshiera
Frequent Visitor

True/False IF statement on two different tables

Let me explain what i'm trying to do and maybe there is an easier way of doing this...

 

Table: Vulnerability

Vul      System

x2123     xyzlaptop

x5252    xyzlaptop

x1235    abclaptop

x3421    deflaptop

Table: Disabled Systems

System

xyzlaptop

deflaptop

 

I want my report to only report on systems that have not been already disabled.  Becuase i've already disabled the systems that have a vulnerability. So I thought I could just to a new comlumn if statmenet =IF vulnerability [system] = Disabled Systems [system],"True","False") However i just keep getting an error that what ever in the Disabled systems field can't be found because i'm trying to create the column in the vulnerability table...   Any help is greatly appreicated.

 

1 ACCEPTED SOLUTION
Vvelarde
Community Champion
Community Champion

@moshiera

 

Hi, assuming that both tables are related.

 

New Calculated Column: 

 

Disabled = IF(COUNTROWS(RELATEDTABLE('Disabled System'))>0,"Yes","No")

 

Regards

 

Victor

Lima - Peru




Lima - Peru

View solution in original post

2 REPLIES 2
v-huizhn-msft
Employee
Employee

Hi @moshiera,

Please create relationship between the tables if there is no connection. Then follow the solution @Vvelarde posted, please give feedback when there is other issue.

Thanks,
Angelia

Vvelarde
Community Champion
Community Champion

@moshiera

 

Hi, assuming that both tables are related.

 

New Calculated Column: 

 

Disabled = IF(COUNTROWS(RELATEDTABLE('Disabled System'))>0,"Yes","No")

 

Regards

 

Victor

Lima - Peru




Lima - Peru

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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