Page 1 of 1

Linq-To-Sql Nullable Boolean

Posted: Wed 26 Apr 2017 09:56
by Les Brinkworth
I see that back in 2010 there was some issue with nullable Boolean comparisons.
I am running the lastest version of LinqConnect 1199.
The following query being performed against a MySQL Database (Ver 5.6.10), always returns false for the (x.editable ?? false) portion of the query. Editable is a nullable Boolean type.

Code: Select all

context.hosted_bundle_service_items.Where(x => x.i_hosted_bundle == i_bundle && (x.editable ?? false))
Please could you explain why this is the case?

Regards

Les Brinkworth

Re: Linq-To-Sql Nullable Boolean

Posted: Thu 27 Apr 2017 16:28
by Shalex
Thank you for your report. We have reproduced the issue and will notify you when it is fixed.

Re: Linq-To-Sql Nullable Boolean

Posted: Fri 26 May 2017 17:26
by Shalex
The bug with returning incorrect data by the 'BooleanProperty ?? false' LINQ query is fixed (MySQL): viewtopic.php?f=31&t=35435.