Alteryx Designer Desktop Discussions

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

Concatenate where a cell is empty or null

JamesDB
7 - Meteor

Hi there,

 

I'm trying to concatenate some address fields but the columns I am using are the content is not uniform and is spread across 3 columns.

 

concatentate.JPG

 

In the example above, I know how to concatenate buildingNumber with the DoubleThoroughfare&descriptor field.  But where DoubleThoroughfare&descriptor field is empty I want to concatenate buildingNumber with the Thoroughfare&descriptor.

 

Is there a way of dong 

5 REPLIES 5
atcodedog05
22 - Nova
22 - Nova

Hi @JamesDB 

 

Use ISNULL in a IF statement and you will be able to get it.

 

Sample formula

 

if isempty(DoubleThoroughfare&descriptor) then

concatenate buildingNumber with the Thoroughfare&descriptor

Else concatenate buildingNumber with the DoubleThoroughfare&descriptor endif

 

I can build you a sample workflow 🙂

 

Emil_Kos
17 - Castor
17 - Castor

Hi @JamesDB,

 

If your data is stirng you can just sum them together using formula tool. 

atcodedog05
22 - Nova
22 - Nova

Hi @JamesDB ,

 

Here is the exact formula 

IF IsEmpty([DoubleThoroughfare&descriptor]) 
THEN ToString([buildingNumber])+"-"+ [Thoroughfare&descriptor]
ELSE ToString([buildingNumber])+"-"+ [DoubleThoroughfare&descriptor]
ENDIF

 

Output:

atcodedog05_0-1601916595202.png

 

Hope this helps 🙂

 

If this post helps you please mark it as solution. And give a like if you dont mind 😀👍

JamesDB
7 - Meteor

That's saved a lot of time and effort.

 

Thank-you.

atcodedog05
22 - Nova
22 - Nova

Happy to help 🙂

 

Cheers and happy analyzing 😀

Labels