How to filter excel

Hi Team,

scenario: I have a excel sheet in below format
input
procode empname empno managername
1234 x 456 a
2345 y 789 b
1234 z 679 a

i want to filter the excel based on procode (let say this case 1234) and for 1234 procode i want to retrive the emp info ,and so on there are so many procodes in my excel input.for each procode i want the emp info .

Thanks and Regards,

Hello Cheerssrpa,

Please find below workflow,

Main.xaml (7.8 KB)
Book1.xlsx (10.3 KB)

Cheers,
Pankaj

Hi @cheersrpa,

Read the excel file into a datatable using Read range activity and follow the below points:

  1. You can use select query to retrive the result based upon procode.
    OR
  2. You can use For Each Row activity and also use if condition to match procode and retrive the result.

hey …thanks for the reply

but i want the procode should be dynamic.

this time you are using assign activity to select the data right

bookDt.Select(“Procode = ‘1234’”).CopyToDataTable()

this 1234 value should be dynamic value.Can you please help me here

Hello,

in for each, take assign activity,

for(row : bookDt) {
bookDt = bookDt.select(“Procode = '”+row(0).ToString+"’")
}

Thanks,
Pankaj

Hi Pankaj,

I tried but no luck…

Here are the sample input for you
testing.xlsx (8.9 KB)