开发者

What's the way to add decimal number to SQL that replicate in EF?

I already tried with decimal(10,4) and float in the SQL but after I updated my Database model the EF treat

decimal(10,4) as a Decimal in C#
float as a Double in C#

witch for me it's great, but the Model Validation always fail

What's the way to add decimal number to SQL that replicate in EF?

and it's not because I'm using . instea开发者_Python百科d of ,

What's the way to add decimal number to SQL that replicate in EF?

What should I do so the validation can run smoothly?

I know I can avoid this using a ModelView in between the View and the Model, but I just want to know how to do things right.


got the problem, it's not me... it's .NET really :)

http://haacked.com/archive/2011/03/19/fixing-binding-to-decimals.aspx

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜