About EasyMorph Tutorials & Examples Web-help

Replace empty cell as text with real empty value


Sometimes, I run into the situation in which I have an empty cell that has “text” as data type when I look in the meta data of that cell.

Is there a way to transform this empty cell to a real empty value (empty()) ?
How should I do this properly using the table-wide replace transformation ?

Thanks in advance !


You can use the “Modify column(s)” transformation with this expression:

[ColumnA] = when(len([ColumnA]) > 0, [ColumnA])

which is a shorthand equivalent of

[ColumnA] = if(len([ColumnA]) > 0, [ColumnA], empty())

Replacing empty text with real empty values not possible with the Table-wide Replace transformation.


Hi Dmitry,

I have noticed that when I transform a column containing text values to numbers with a data type transformation, that the blank cells are not converted to empty() values.
Is this the normal behavior ? Is there a workaround for replacing these for the entire dataset or do I have to do the transformation you proposed for each column individually ?

Thanks in advance !


Hi Nikolaas,

this is expected behavior as converting text to numbers doesn’t necessarily mean that empty text values should be converted to nulls. At this point the only option is to use the expressions I suggested above.


Ok thanks for the response !