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
Anonymous
Not applicable

Condition based formatting

Hi,

 

I have this data and want to change the Decline status of them:

 

sds.PNG

 

So prevoiusly Mother cases could have 4 different status and now they only have 3. Daughter had 6 different and now it is also down to thrree. I cant just replace value as "Not applicable as GP", in the case of daughter translates to something different than in the case the type is mother.

 

Any help how I can do this would be much appreciated. I would prefer to do the changes in query.

 

Also, this data is updated continously but all new informaiton will be correct to the 3 new decline statuses. So if I could just change the existing values in the column and ignore any new that would be great.

 

Regards
M

2 REPLIES 2
PattemManohar
Community Champion
Community Champion

@Anonymous  You can try using the Lookup Table where you have CascadeType and Decline Status (New) and DeclineStatus (Old). Use this lookup table in your calculated column using LOOKUPVALUE function to dervie the new DeclineStatus, when there is no match found then you can add another condition for Mother and Daughter in the logic. Doing this way will simplify and it is future proof as well !

 

Note - If you can post the sample data in text format then it will be useful to copy and paste than the image format.





Did I answer your question? Mark my post as a solution!

Proud to be a PBI Community Champion




Anonymous
Not applicable

@PattemManohar sorry, I am quite new to Power BI and not sure how to do this. Do you mean that I should create a new table with the correct "translation" and then add a calculated column in the table with all data from database? So I cant go in and change in the existing column then?

 

Here is the table again

What I have What I want
   
Cascade typeDecline status (old)Decline status (new)
MotherNot applicableNot applicable as GP
MotherNot applicable as GPNot applicable as GP
MotherWeak of quality in GPPoor quality of GP
MotherAlready implementedSimilar already implemented
MotherNot applicableNot applicable as GP
DaughterNot applicable as GPNot applicable to the factory
DaughterWeak of quality in GPPoor quality of GP
DaughterWeak of quality in GPPoor quality of GP
DaughterNo loss existNot applicable to the factory
DaughterNo resourcesNot applicable to the factory
DaughterSimilar ImplementedSimilar already implemented
DaughterSimilar ImplementedSimilar already implemented
DaughterNot applicableNot applicable to the factory
DaughterNo loss existNot applicable to the factory
DaughterNo resourcesNot applicable to the factory
DaughterNo resourcesNot applicable to the factory
DaughterNot applicable as GPNot applicable to the factory
DaughterNot applicable as GPNot applicable to the factory

 

Regards

M

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.