OData: Do case insensitive comparison using ExpressionVisitor
<p>For example, i have OData query such as these:</p>

<ul>
<li>/Suppliers?$filter=Address/City eq 'city'</li>
<li>/Suppliers?$filter=contains(Address/City, 'city')</li>
<li>/Suppliers?$filter=endswith(Address/City, 'city')</li>
</ul>

<p>...</p>

<p>and Address/City only has "City". I still want the query to return that record.</p>

<p>I read <a href="https://stackoverflow.com/questions/17428406/case-insensitive-string-compare-in-linq-expression">this</a> already but it only appear to address contains function. I could easily fix for other functions but eq is more difficult.
To make it simpler, i was thinking about just replacing all string const to uppercase by doing this .ToString().ToUpper().</p>

<p>I am having a problem because i can't really access the value.</p>

<pre><code>protected override Expression VisitConstant(ConstantExpression node)
            {
//the node.Value i get here is {value(System.Web.OData.Query.Expressions.LinqParameterContainer+TypedLinqParameterContainer`1[System.String])} 
and of type System.Linq.Expressions.ConstantExpression.
</code></pre>

<p>How can i either modify the value directly to upper case or add a call to ToString and ToUpper?</p>