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
siva54
Helper I
Helper I

Asset Description with same class

Hi Team,

 

I need a calculated column for the below criteria.

 

we have differnent asset classes with different asset description with their codes.


Here, For Example:- Asset Description are{ Fan, Pen, Chair, Table....}
                                Asset Classes Like{A,B,C....}

                                Codes{H,I..}

Here, Class "A" have Asset description like Fan and Pen. then These two asset description should not associate with Other Classes like{B,C..} with in the Same code. then result is Not Anamoly.
If the description are associated with other classes in Same Code then it is Anamoly.

 

Find the below Capture.

siva54_0-1635226098316.png

 

 

In above picture, Asset class A have Fan and Pen with Code "I". But Pen is associated with Asset class "C" with Same code I, then all "pen" are Anamoly

Fan is Associated with Asset Class B, But with different Code, then it is fine &  it's should be not Anamoly.

 

Thanks in Advance.


If the code is different then it is fine

1 ACCEPTED SOLUTION
Fowmy
Super User
Super User

@siva54 

Add the following column:

Check = 

VAR _DES = Table1[Asset Description]
VAR __CLASS = Table1[Asset class]
VAR _CODE = Table1[Code]
VAR _LIST = CALCULATETABLE( VALUES(Table1[Code]), Table1[Asset Description] = _DES , Table1[Asset class] <> __CLASS, REMOVEFILTERS( ) )
RETURN
    IF ( _CODE IN _LIST , "ANAmoly" , "Not An" )

Fowmy_0-1635237857967.png

 



Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

3 REPLIES 3
v-yanjiang-msft
Community Support
Community Support

Hi @siva54 ,

According to your description, heres my solution.

vkalyjmsft_0-1635404744417.png

 

Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Fowmy
Super User
Super User

@siva54 

Add the following column:

Check = 

VAR _DES = Table1[Asset Description]
VAR __CLASS = Table1[Asset class]
VAR _CODE = Table1[Code]
VAR _LIST = CALCULATETABLE( VALUES(Table1[Code]), Table1[Asset Description] = _DES , Table1[Asset class] <> __CLASS, REMOVEFILTERS( ) )
RETURN
    IF ( _CODE IN _LIST , "ANAmoly" , "Not An" )

Fowmy_0-1635237857967.png

 



Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

wdx223_Daniel
Super User
Super User

Final Out Put=IF(CALCULATE(DISTINCTCOUNT(TableName[Asset class]),ALLEXCEPT(TableName,TableName[Asset description]))>1,"Anamoly","Not Anamoly")

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.

Top Solution Authors