Clear filter data table

I use “for each” data table to iterate through all the rows in a table. Inside the “for each” loop, based on certain conditions (if statements), I use “filter data table” to filter another table. However, in the next iteration, when I need to enter a different condition, the filter from the table is not cleared. How can I clear it?

hi @plamenov.plamen
use filter without looping
you can set the condition inside the filter

Hi @plamenov.plamen

For Each Row in DataTable
Filter Data Table (Condition 1) - Output: filteredDataTable
Process filteredDataTable
Remove Data Row (DataTable: filteredDataTable, Index: -1) - This will remove all rows from the DataTable
Filter Data Table (Condition 2) - Output: filteredDataTable
Process filteredDataTable
Remove Data Row (DataTable: filteredDataTable, Index: -1) - This will remove all rows from the DataTable
Next

Hope it helps!!

Hi @plamenov.plamen

In filter datatable wizard there is the value field in that field you can pass the variables. In the loop you can change the variable data. Here we are changing the filter for every loop.

Hope it helps!!

hi

Remove Data Row: There is no row at position -1.

@plamenov.plamen
Hi,
You can’t delete multiple rows in datatable throw remove data row by putting loop.
Try to use Filter Activity, if it is much complex then use Linq query.