We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Data Modification by Adding "FR" at the Beginning of a Word

Franzil
8 - Asteroid

Dear Team,

 

I hope this message finds you well.

 

I am seeking assistance with a workflow adjustment. Specifically, I need to identify all sample numbers that begin with 76, 77, 74, and 71, and update them to "FR" in the Bucket column. Depending on the current designation in the Bucket column, these should be labeled as "FR ALPHA" or "FR BETA." If the specified conditions are not met, the entries should remain unchanged as "ALPHA" or "BETA."

 

@flying008 already solved this by creating a formula below and thanks to that however, In any chance, is there a way to get a the same output without using a hard code or a formula tool?

 

IIF(Left(ToString([Sample]), 2) in ('71','74','76', '77'), 'FR ' + [Bucket], [Bucket])

 

 

I would greatly appreciate any guidance or support you can provide on this matter.

 

Thank you in advance for your assistance.

 

 

Best regards,

Franzil

11 REPLIES 11
alexnajm
18 - Pollux
18 - Pollux

What are you hoping would be different? This seems like a solid formula to me that meets all your requirements

Franzil
8 - Asteroid

Hi @alexnajm ,

 

The future user doesn't want to use hard codes that will eventually or possibly be changed in the future. By doing so, it prevents consuming of time and efforts in enhancement.

OTrieger
13 - Pulsar

@Franzil 
No sure what is the issue here, as the formula will not change, only the variables might.

You can get the list (71,.....) from external file, and then set a field name instead of the individual values.

It is very simple, connect excel that contain the needed value and with Summarize tool concatenate them into a list, and use that field as the variable.

alexnajm
18 - Pollux
18 - Pollux

@Franzil knowing that the numbers could change was not mentioned before so that's why we needed clarity!

 

I would agree with @OTrieger about that solution

Franzil
8 - Asteroid

@alexnajm @OTrieger Yeah, numbers could change and I apologize that I forgot to mention that. Thank you guys for answering.

alexnajm
18 - Pollux
18 - Pollux

All good @Franzil - try out the external list option and see if that tackles your challenge!

flying008
15 - Aurora

Hi, @Franzil 

 

FYI.

录制_2025_02_20_09_57_43_748.gif

 

Franzil
8 - Asteroid

@flying008 you're the best! Thank you so much always for the help. This helps a lot. KUDOS!

Franzil
8 - Asteroid

Hi@flying008, I'm just bit confuse re the Find Replace tool. How did you come up with another column for showing all the prefixes? I'm just bit confuse since I can't configure that. Sorry but I'm just new here.

Labels
Top Solution Authors