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.
解決済み

How to create an 'if contains' formula

jgpwc1992
アトム

I am trying to write a formula given the following:

 

first column contains list of identifiers, I have created a second column. I would like the second column to be populated by any identifiers containing the text "LX" in the corresponding rows. If the identifier in column 1 does not contain "LX", the corresponding cell in the second column should remain blank.

 

Something to the effect of an 'if cell A1 contains "LX", then B1 = A1, if not null'

 

 

4件の返信4
Claje
マグネター

Hi,

 

Assuming your columns were named [A] and [B] in that example, here's a formula that should work:

IF CONTAINS([A],'LX') THEN [A] ELSE NULL() ENDIF

You should write this formula on Column B so that it is the one that is updated.

 

BenMoss
ACE Emeritus
ACE Emeritus
IF CONTAINS([fieldA],"LX") THEN [fieldA] ELSE NULL() ENDIF
jgpwc1992
アトム

Thank you!

martin_iglesias
アトム

martin_iglesias_0-1679940852848.png

 

ラベル
トップのソリューション投稿者