Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Formula Tool

guadalupemota
6 - Meteoroid

Hi,

 

I have a data set where on my "Xlarge bags" column there is an O instead of a zero. and down the column there's other numbers that should stay as is. I only need to change the alphabet letter O to 0.

 

I used the formula tool and I put:

IF [XLarge Bags] = "O"

THEN "0" 

ELSE "0"

ENDIF

 

However, this formula changed the whole columns to zeros and I only needed that row with O to change to 0.

 

Please advise!

 

Thank you,

 

Guadalupe  

3 REPLIES 3
fmvizcaino
17 - Castor
17 - Castor

Hi @guadalupemota ,

 

You should use the following:

IF [XLarge Bags] = "O"

THEN "0" 

ELSE  [XLarge Bags] 

ENDIF

 

Best,

Fernando V.

Simha
9 - Comet

Please replace your entire code with below:

 

Replace([Xlarge bags], "O", "0")

 

Your code is replacing the entire column with 0.

 

Regards

Simha

 

guadalupemota
6 - Meteoroid

Thank you Fernando! That formula solved my issue!

Labels