Page 1 of 1

LinqConnect Professional Version 4.4.374 (14-Nov-2013) - Problems comparing dates in Single and First statement

Posted: Tue 03 Dec 2013 18:03
by motaboyrs
Hello.

When we upgraded Devart LinqConnect to 4.4.374, we discovered a bug when comparing dates.

For example:
listResults.FirstOrDefault(f => f.StartDate == DateTime.Now); // This works fine
listResults.FirstOrDefault(f => DateTime.Now == f.StartDate); // This throws an error: InvalidCastException.

In the version 4.1.169 it was working.

I have an example solution. How can I send it to you?

Re: LinqConnect Professional Version 4.4.374 (14-Nov-2013) - Problems comparing dates in Single and First statement

Posted: Wed 04 Dec 2013 09:26
by MariiaI
Thank you for the report on this. We have reproduced this issue. We will investigate it and inform you about the results as soon as possible.

Re: LinqConnect Professional Version 4.4.374 (14-Nov-2013) - Problems comparing dates in Single and First statement

Posted: Fri 13 Dec 2013 06:25
by MariiaI
The bug with the comparison of constant with the column value, when the constant is on the left of the comparison operator, is fixed.
New build of LinqConnect 4.4.393 is available for download now!
It can be downloaded from http://www.devart.com/linqconnect/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?f=31&t=28506.