Error in data table LINQ query

I am extracting datatable from website using Extract Data table component.
After this I am writing a LINQ query as given below
Assign strCount =
(From row In dtOutput
Where CDate(dtOutput(“Date”)) >= CDate(strStartofWkDate)
Select row

However this is giving error - Option strict on disallows implicit conversions from ‘String’ to ‘Integer’
I suppose the data type of date value in table is “Date”.

I am not able to get what could be the issue, Any help in this would be appreciated.


welcome to the forum
have a look here:
:ambulance: :sos: [FirstAid] Datatable: Debug & Analysis invalid DateTime Strings / String to DateTime Parsing Issues - News / Tutorials - UiPath Community Forum

the described analysis statements used within the immediate panel can be modified as well

ensure also that dtOutput.AsEnumerable is used within the LINQ

Hi @sudhakar_kb ,

It looks like you’re using the dtOuptut variable itself instead of row in CDate , Check the following Updated Query :

(From row In dtOutput
Where CDate(row("Date").ToString) >= CDate(strStartofWkDate)
Select row

If still there are errors, Follow the Post mentioned by @ppr in the above post.

Let us know if you get different errors or it doesn’t work as expected.

1 Like

The issue is resolved. Thank you @ppr and @supermanPunch.