[英]Why do I get an error when submitting to OData Edm.Decimal type?
I'm trying to submit some JSON to an OData service.我正在尝试将一些 JSON 提交给 OData 服务。 According to the $metadata, it expects this type:
根据 $metadata,它需要这种类型:
<Property Name="curClaimValue" Type="Edm.Decimal" Nullable="true" Precision="19" Scale="4"/>
This is part of my JSON:这是我的 JSON 的一部分:
..."curClaimValue":654321... ...“curClaimValue”:654321 ...
And this is the error message:这是错误消息:
Error processing request stream.错误处理请求 stream。 Error encountered in converting the value from request payload for property 'curClaimValue' to type 'Decimal', which is the property's expected type.
将属性“curClaimValue”的请求负载中的值转换为类型“十进制”时遇到错误,这是该属性的预期类型。
Let me know if you need more information.如果您需要更多信息,请与我们联系。
Thanks, Stephen谢谢,斯蒂芬
Seems I have to wrap the number in quotes.似乎我必须将数字用引号括起来。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.