Filter year/Date from excel

I need to filter data start from 2020 in column planned start,Can i use filter data table activity in this case?Untitled

1 Like

Yes you can

1 Like

Why i cant use contains? “Planned start” Contains “2020”.Is that wrong?

help please

are you using it in filter datatable activity?

yes i use in filter datatable

1 Like

Then it will work…

yes it work but not accurate

accurate in terms of???

I need a count from “phase” = deployment ,“planned start”="2020"

it state zero

you can use Datatable.Select method to query -
like below -

dt1.Select(“phase = ‘deployment’ and planned start like ‘%2020%’”)

3 Likes

@kuih_sedap Can you try this Linq :
DT1.AsEnumerable().Where(Function(row) row(“Phase”).ToString.Trim.Tolower.Equals(“deployment”) and row(“Planned Start”).ToString.Trim.Tolower.Contains(“2020”)).CopyToDataTable

@kuih_sedap

Please check your input excel file, if it actually has “Planned Start” to be containing “2020” and
“Phase” to be equal to be “Development”…

I never saw the above combination in your screenshots of excel file.

Check if you are dealing with the correct excel…

As i checked with Filter data table… I was able to filter my dummy data using the conditions…

Thanks and Regards,
@hacky,

The file is right,I’ve filtered manually and the data is right.

But it still state zero

@kuih_sedap
Can you share your excel?

I will create a flow and share with you instantly.

@kuih_sedap

I guess there was something wrong with the excel (atleast in my case)…

When I try to open the excel file manually, i get below error:-

Also, When I try to open the excel file using the UiPath activity(Read Range - Workbook), I get the below error:-

Kindly help me understand, what exactly is happening here, in my case.

Thanks and Regards,
@hacky

@kuih_sedap Can you try this and Check
FilterDT.zip (65.1 KB) is and Check :sweat_smile:

2 Likes

How can i select multiptle items from column Phase?

@kuih_sedap you’ll need to modify the Linq Query a bit, Tell me the condition