When I select with a simple condition as follows, it works fine and produces the following correct SQL:
Code: Select all
var x = ctx.Test.Where(z => (bool)z.Active);
Console.WriteLine(x.Count());
Code: Select all
SELECT COUNT(*)
FROM TEST "z"
WHERE "z".ACTIVE = 1
Code: Select all
x = ctx.Test.Where(z => (bool)z.Active && (bool)z.Active);
Console.WriteLine(x.Count());
Code: Select all
SELECT COUNT(*)
FROM TEST "z"
WHERE "z".ACTIVE AND "z".ACTIVE