Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.
Hi!
I need help making a column that "standarizes" names. Example:
Manufacturer | Standarized manufacturer |
Manufacturer A | Manufacturer A |
ManB | Manufacturer B |
ManufacturerA | Manufacturer A |
Man A | Manufacturer A |
Man A. | Manufacturer A |
Manufacturer B | Manufacturer B |
ManufacturerB | Manufacturer B |
Thanks in advance!
Solved! Go to Solution.
Hi @Anonymous ,
in a query Editor, hit on custom Column and add this code:
if Text.Contains([Manufacturer], "A") then "Manufacturer A" else "Manufacturer B"
let me know if this works.
My output:
Thanks,
Tejaswi
Hi @Anonymous ,
In a Query editor,
you can select this column and right click-> Replace values.
or else you can use the IF statements/SWitch statemnts in a calculated column if you have a small data as in your sample data.
here the formula with IF
Standardized manufacturer = if(Sheet18[Manufacturer]="Man A"|| (Sheet18[Manufacturer])="Manufacturer A" || (Sheet18[Manufacturer])= "ManufacturerA"|| (Sheet18[Manufacturer])= "Man A." ,"Manufacturer A", "Manufacturer B")
My output with the above Calculated Colum:
You can also use the DAX measure like this:
Measure 3 = Maxx(Sheet18, Var mylist4= {"Man A", "Man A.", "Manufacturer A", "ManufacturerA"} return IF (Sheet18[Manufacturer] in mylist4, "Manufacturer A", "Manufacturer B" ))
Thanks,
Tejaswi
Thanks!
Is there anyway to make it like, if it detects the "A" it knows its manufacturer A?
Hi @Anonymous ,
in a query Editor, hit on custom Column and add this code:
if Text.Contains([Manufacturer], "A") then "Manufacturer A" else "Manufacturer B"
let me know if this works.
My output:
Thanks,
Tejaswi
Check out the November 2023 Power BI update to learn about new features.
Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.