cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
steambucky Member
Member

Replace all different values except one

I have a column of data

 

Cat

Dog

Mouse

ANIMAL UNKNOWN

ANIMAL UNKNOWN

ANIMAL UNKNOWN

 

I want to replace everything except ANIMAL UNKNOWN TYPE with ANIMAL TYPE KNOWN.

 

I have far more than 3 types of animals - actually about 100. There loads of examples for getting rid of specific text but i can't find anything that gets rid of everything BUT a specific thing.  If you can help, the less coding or DAX stuff, the better. I am but a humble noob.  

 

Thanks in advance.    

1 ACCEPTED SOLUTION

Accepted Solutions
RahulYadav Regular Visitor
Regular Visitor

Re: Replace all different values except one

Hi @steambucky,

You can use below dax formula to solve your problem.

 

Resived Name = if(Animals[Name]<>"ANIMAL UNKNOWN","ANIMAL TYPE KNOWN",Animals[Name]) 

Thanks,

Rahul

1 REPLY 1
RahulYadav Regular Visitor
Regular Visitor

Re: Replace all different values except one

Hi @steambucky,

You can use below dax formula to solve your problem.

 

Resived Name = if(Animals[Name]<>"ANIMAL UNKNOWN","ANIMAL TYPE KNOWN",Animals[Name]) 

Thanks,

Rahul