Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Replace Formula

Ayaanarjun-5885
8 - Asteroid

Hi, I have few IDs and I wanted to replace them using single formula tool with below referred values and extract the min value in another new column. Can someone help me with this. Replacement values are,

ABC=1
XYZ=2
PQR=3
UVW=4

 

Input:

IDs
ABC,XYZ
PQR 
PQR,ABC,UVW
UVW,PQR
XYZ,PQR
ABC

 

Output:

IDsReplacing IDs with referred valuesMin value
ABC,XYZ1,21
PQR 33
PQR,ABC,UVW3,1,41
UVW,PQR4,33
XYZ,PQR2,32
ABC11
4 REPLIES 4
aatalai
15 - Aurora

@Ayaanarjun-5885 take a look at this and let me know if it helps

 

replace formula.PNG

binuacs
21 - Polaris

@Ayaanarjun-5885 Here is another way

image.png

terry10
12 - Quasar

@Ayaanarjun-5885 , Here's another way you can accomplish this using the Switch function. I hope this is useful!

 

replace formula.PNG

terry10
12 - Quasar

Be sure to check your results when using the Find-Replace tool. Sometimes the output is not what's expected.

Labels
Top Solution Authors