How to replace empty data table with missing values/integer

Hi all,

I am currently stuck on this problem with replacing blank cells with missing values or an integer.
In this example I split the rows based on this GG level to find the count within each level.

image
image

Based on different data sets, the GG level(s) may or may not have rows to filter. In the instance that there aren’t any rows to filter, I would like to find a way to replace the empty data table with missing values or an integer.

What is the best way to go about this? I’ve tried using the Column Auto Type Cast node and String Manipulation’s toNull() function, but no success. I hope that someone here can help me out.

Thank you in advance and have a nice day.

@Ammar_Muhammad,

If I understand the issue correctly, I think you should be able to resolve it by using the Add Empty Rows node.

@Ammar_Muhammad welcome to the KNIME forum.

Here is a way how to deliberately create null values with the help of the rule engine

Thank you for your reply. I will try this out and see if it leads to my desired outcome

Thank you for your reply. Unfortunately I’m not looking to deliberately create NULL values. Rather, I would like to covert NULL values into missing values

Have you tried emtpy table switch node?
br

Yep I have tried. Unfortunately, it doesn’t work for me

Hi @Ammar_Muhammad , there is a toNull() function in the Column Expressions node or in the String Manipulation node too. Please read the documentation about how to use the function (you can click on the function in either node to see how to use it)

2 Likes