Code First和TimeSpan属性 [英] Code First and TimeSpan properties

查看:71
本文介绍了Code First和TimeSpan属性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这不支持TimeSpan吗? 当我有TimeSpan属性时,我得到以下异常。

Does this not support TimeSpan?  I get the following exception when I have a TimeSpan property.

没有与概念边类型'Edm.Time(Nullable = True,DefaultValue =,Precision =)'对应的商店类型PrimitiveType'时间'。

There is no store type corresponding to the conceptual side type 'Edm.Time(Nullable=True,DefaultValue=,Precision=)' of PrimitiveType 'Time'.

推荐答案

错误消息表明数据库提供程序没有用于存储时间值的类型.Microsoft SQL Server支持使用TimeSpan,你是否使用不同的提供商


这篇关于Code First和TimeSpan属性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆