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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Geminidad
New Member

Transformation for all other values

My file has a column containing a two letter code representing the group. There are about 25 unique codes.

To combine this file with one from another source, I need to align these values with the codes used in that other file.

Code CB is replaced with Dentist, CI is replaced with IC, CP with Patient and all others with STD.

The first three replacement are tstraightforward, but how can I handle that last one without having to do it one by one for the remaining 22 unique values?

- wildcards do not work

- I can filter out the first three but then I am left with a subset and cannot figure out how to bring back the other records.

 

How can I setup a flow that works?

Thnx

1 ACCEPTED SOLUTION
DOLEARY85
Resident Rockstar
Resident Rockstar

Hi,

 

can you create a new column in power query to convert all the codes prior to a join e.g

 

if [CODE] = "CP" then "Patient" else if [CODE] = "CI" then "IC" else if [CODE] = "CB" then "Dentist" else "STD"

 

DOLEARY85_0-1687380153777.png

 

 

If I answered your question, please mark my post as solution, Appreciate your Kudos 👍

View solution in original post

2 REPLIES 2
DOLEARY85
Resident Rockstar
Resident Rockstar

Hi,

 

can you create a new column in power query to convert all the codes prior to a join e.g

 

if [CODE] = "CP" then "Patient" else if [CODE] = "CI" then "IC" else if [CODE] = "CB" then "Dentist" else "STD"

 

DOLEARY85_0-1687380153777.png

 

 

If I answered your question, please mark my post as solution, Appreciate your Kudos 👍

Thank you for the quick reply. Looks like a good solution, I will put that in my workflow for this file. 👍

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.