Comparison operators for IS and IS NOT are commented out? #211

Closed
toptensoftware opened this Issue Jun 14, 2010 · 1 comment

2 participants

@toptensoftware

In QueryVisitor.VisitBinary(BinaryExpression b) the following code is commented out:

        //else if (b.NodeType == ExpressionType.NotEqual && current.ParameterValue == null)
        //    current.Comparison = Comparison.IsNot;
        //else if (b.NodeType == ExpressionType.Equal && current.ParameterValue == null)
        //    current.Comparison = Comparison.Is;

This prevents fluent Where expression for null to fail:

eg:

Update<table>() ... Where<tablename>(x=>x.field==null)

generates SQL:

WHERE 'field' = @0

instead of

WHERE 'field' IS NULL
@saintedlama
Collaborator

Fixed

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment