Alteryx Designer Desktop Discussions

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

Formula to identify any character in a column?

pacbloyd
7 - Meteor

Hi - I need to concatenate two columns if the 2nd one contains anything - any character at all.

 

So far I have 

 

IF contains([COLUMN 2],' ') THEN [COLUMN 1] + [COLUMN2]
ELSE [COLUMN 1]
ENDIF

 

I know the ' ' is incorrect as it includes empty cells, but how do I write for IF a cell contains any data?

 

Or does it need a notNull or not empty?

 

EDIT: Figured it out using notNull:

 

IF IsNull([Col 2]) THEN [Col 1] 
ELSE [Col 1] + ' ' + [Col 2]
ENDIF
2 REPLIES 2
gabrielvilella
14 - Magnetar

Hi, you can use the !IsNull() or !IsEmpty() formulas. The exclamation mark at the beginning means the oposite, so 'is not null' for instance. 

Luke_C
17 - Castor

Worth noting that IsEmpty picks up both nulls and empty cells, whereas IsNull would not count empty cells

Labels