In case you missed the announcement: Alteryx One is here, and so is the Spring Release! Learn more about these new and exciting releases here!

Alteryx Designer Desktop Discussions

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

Converting to string for replace formula

Anasitani
6 - Meteoroid

Hello,

 

I am having an issue with a formula on Alteryx. So I'm trying to replace an x with a "Yes" and a "No" with nothing. The problem is that for some reason Alteryx reads it as a Numeric field and thus doesn't accept the replace functions. Ive attached the file below.

5 REPLIES 5
IraWatt
17 - Castor
17 - Castor

Hey @Anasitani,

Can you attach the data for the workflow?

IraWatt_0-1654859659732.png

 

binuacs
21 - Polaris

@Anasitani @I think you are using two replace functions in the same tool which is causing the issue. Can you try with one Replace function and check the result ? 

Anasitani
6 - Meteoroid

Hi IraWatt,

 

I remade it using the text input.

 

Many thanks


Anas

Anasitani
6 - Meteoroid

Hi binuacs,

 

I tried but unfortunately to no avail.

 

Many thanks

 

Anas

IraWatt
17 - Castor
17 - Castor

Hey @Anasitani,

Think this is what you are looking for:

IraWatt_0-1654861570746.png

I changed it to update the field not output a copy. Also you used 'AND' that is only for logical expressions. To replace both you can use two tools or one tool using this formula:

Replace( Replace([_CurrentField_],"No",NULL()) ,"x","yes")

Any questions or issues please ask :)
HTH!
Ira

 

Labels
Top Solution Authors