-
Notifications
You must be signed in to change notification settings - Fork 137
Closed
Description
metadata:
<EntityType Name="Person"><Key><PropertyRef Name="PersonId"/></Key><Property Name="PersonId" Type="Edm.Int64" Nullable="false"><Annotation Term="Org.OData.Core.V1.Computed" Bool="true"/></Property><Property Name="UserName" Type="Edm.String" MaxLength="max"/><Property Name="FirstName" Type="Edm.String" Nullable="false" MaxLength="max"/><Property Name="LastName" Type="Edm.String" MaxLength="26"/><Property Name="Concurrency" Type="Edm.Int64" Nullable="false"/><NavigationProperty Name="Friends" Type="Collection(Microsoft.Restier.WebApi.Test.Services.Trippin.Models.Person)"/><NavigationProperty Name="Trips" Type="Collection(Microsoft.Restier.WebApi.Test.Services.Trippin.Models.Trip)"/></EntityType>
http://localhost:18384/api/TripPin/People%280%29/
Response:
HTTP/1.1 500 Internal Server Error
Cache-Control: no-cache
Pragma: no-cache
Content-Type: application/json; odata.metadata=minimal
Expires: -1
Server: Microsoft-IIS/8.0
OData-Version: 4.0
X-AspNet-Version: 4.0.30319
X-SourceFiles: =?UTF-8?B?RDpcZ2l0XHRcUkVTVGllclx0ZXN0XE9EYXRhRW5kVG9FbmRUZXN0c1xNaWNyb3NvZnQuUmVzdGllci5XZWJBcGkuVGVzdC5TZXJ2aWNlcy5UcmlwcGluXGFwaVxUcmlwUGluXFBlb3BsZSgwKVw=?=
X-Powered-By: ASP.NET
Date: Mon, 20 Jul 2015 08:39:23 GMT
Content-Length: 3466
{
"error":{
"code":"","message":"An error has occurred.","innererror":{
"message":"The binary operator Equal is not defined for the types 'System.Int64' and 'System.Int32'.","type":"System.InvalidOperationException","stacktrace":" at System.Linq.Expressions.Expression.GetEqualityComparisonOperator(ExpressionType binaryType, String opName, Expression left, Expression right, Boolean liftToNull)\r\n at System.Linq.Expressions.Expression.Equal(Expression left, Expression right, Boolean liftToNull, MethodInfo method)\r\n at System.Linq.Expressions.Expression.Equal(Expression left, Expression right)\r\n at Microsoft.Restier.WebApi.ODataDomainController`1.CreateEqualsExpression(ParameterExpression parameterExpression, String propertyName, Object propertyValue) in d:\\git\\t\\RESTier\\src\\Microsoft.Restier.WebApi\\ODataDomainController.cs:line 383\r\n at Microsoft.Restier.WebApi.ODataDomainController`1.ApplyKeys(IQueryable queryable, KeyValuePathSegment keySegment, IEdmEntityType entityType, Type type) in d:\\git\\t\\RESTier\\src\\Microsoft.Restier.WebApi\\ODataDomainController.cs:line 313\r\n at Microsoft.Restier.WebApi.ODataDomainController`1.GetQuery(HttpRequestMessageProperties odataProperties) in d:\\git\\t\\RESTier\\src\\Microsoft.Restier.WebApi\\ODataDomainController.cs:line 510\r\n at Microsoft.Restier.WebApi.ODataDomainController`1.<Get>d__0.MoveNext() in d:\\git\\t\\RESTier\\src\\Microsoft.Restier.WebApi\\ODataDomainController.cs:line 126\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Threading.Tasks.TaskHelpersExtensions.<CastToObject>d__3`1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__2.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__1.MoveNext()"
}
}
}