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
{{ message }}
Repository navigation
Support nullable (alternate) keys in ODataPathQueryBuilder #2888
Currently if I have a nullable property (like int?) used in an alternate key ODataPathQueryBuilder throws an exception when processing the generated KeySegment (with an int constant value):
System.InvalidOperationException: The binary operator Equal is not defined for the types 'System.Nullable`1[System.Int32]' and 'System.Int32'.
at System.Linq.Expressions.Expression.GetEqualityComparisonOperator(ExpressionType binaryType, String opName, Expression left, Expression right, Boolean liftToNull)
at System.Linq.Expressions.Expression.Equal(Expression left, Expression right, Boolean liftToNull, MethodInfo method)
at ...\ODataPathQueryBuilder.cs:line 69
...
@habbes sorry for the late response, it seems I cannot contribute until the related issue is solved, nullable keys are not supported in odata.net yet, so I cannot run the appropriate unit tests
Activity
habbes commentedon Nov 11, 2025
Hello @Xriuk, would you be open to contributing a PR to address this?
Xriuk commentedon Dec 3, 2025
@habbes sorry for the late response, it seems I cannot contribute until the related issue is solved, nullable keys are not supported in odata.net yet, so I cannot run the appropriate unit tests