You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
KORM fails to parse correct condition for NULL comparison.
Steps To Reproduce
Example:
var test = _database.Query<MovementsOverviewSearchResult>()
.Where(x => x.PartnerName != null);
Expected behavior
LINQ query above should be parsed
SELECT ... FROM ... Where (PartnerName IS NOT NULL)
Actual behavior
KORM parses the query as
SELECT ... FROM ... Where (PartnerName <> NULL)
Comparing NULL with anything using operators =, !=, <> ALWAYS produces FALSE. Even NULL = NULL is FALSE. Therefore, IS and IS NOT keywords should be parsed instead when comparing with NULL.
The text was updated successfully, but these errors were encountered:
Library name and version
Description
KORM fails to parse correct condition for NULL comparison.
Steps To Reproduce
Example:
Expected behavior
LINQ query above should be parsed
Actual behavior
KORM parses the query as
Comparing NULL with anything using operators =, !=, <> ALWAYS produces
FALSE
. EvenNULL = NULL
isFALSE
. Therefore,IS
andIS NOT
keywords should be parsed instead when comparing with NULL.The text was updated successfully, but these errors were encountered: