Filter a row if all "Double" or "Integer" columns are 0.

Hi,
Is there a way to filter an entire row if, for example, all double columns are 0 ?

I’ve a database with a lot of rows there are more here as a place-holder but in reality have no data.
I’m using the node “Rule-based Row Filer” with NOT $Col1$=0=> FALSE, NOT $Col2$=0=> FALSE, … but it’s long as I’ve to add all columns.
I’m wondering if there is a node that permits to filter a row if all column “Double” or “Integer” are 0 ?

Thank you.
Laurent

Hi @Zarkoff95

With the Column Aggregator you can filter with “Type Selection” on Integers and/or Doubles. In the options tab you can use e.g. Sum as Aggregation Setting. And then use a row filter node to filter on the new column where the value = 0.

gr.
Hans

5 Likes

It works,
Thank you.

2 Likes

Assuming there are no negative values…Sum can be 0 even if no column actually is 0.

Is there a way to filter an entire row if, for example, all double columns are 0 ?
I’ve a database with a lot of rows there are more here as a place-holder but in reality have no data.

Then fix your data. 0 should never ever be used as a placeholder. That is why null exists.

3 Likes

@beginner, agree, my solution can be little bit tricky in some situations.
gr. Hans

Hello,

to add to @HansS solution instead of Sum use Max and Min aggregations. Then filter if both are equal to zero.

Br,
Ivan

3 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.