The Alteryx Community is a finalist in three 2026 CMX Awards! Help us win Customer Support Community, Most Engaged Community, and User Group Program of the Year - vote now! (it only takes about 2 minutes) before January 9.
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
RÉSOLU

New field creation based on rules

pranee_007
Météore

Hi team,

 

I am looking to add a new field based on the below conditions. Please help.

1. If the field 'Reference' is Check (case insensitive), a new column 'Code' should be added and assign a value Not-found to that.

2. If it sees the key word app in any case (case insensitive), I want the new field to be populated with the 9 digits after keyword app.

 

Example:

ReferenceCode
CheckNot-found
appv56789Supv56789Sup
APPf63889Dspf63889Dsp
aPpr67299Luyr67299Luy
checkNot-found
1 RÉPONSE 1
LordNeilLord
Aurore

Hey @pranee_007 

 

A simple formula should suffice here:

 

If Contains([Reference], "app") Then Regex_Replace(Reference, "app", "") Else "not found" endif

Étiquettes
Auteurs des meilleures solutions