我有一个非常简单的代码,它使用SqlEntityConnection类型提供程序。
基本上是这样的
open System.Data.Linq
open System.Data.Entity
open Microsoft.FSharp.Data.TypeProviders
type private EntityConnection = SqlEntityConnection<ConnectionString="ConnectionString",
Pluralize = true>它在Windows上编译得很好,但是当我试图在Mac上编译它时,它失败了
The type provider 'Microsoft.FSharp.Data.TypeProviders.DesignTime.DataProviders' reported an error: Error reading schema. The required tool '/Library/Frameworks/Mono.framework/Versions/4.0.1/lib/mono/4.5/edmgen.exe' could not be found.
我到处找,似乎找不到edmgen.exe。它应该安装在单机上吗?我安装了MDK4.0.1.44,而edmgen.exe不在那里。我遗漏了什么?
发布于 2015-07-04 00:53:30
经过了很多试验,包括从Windows复制edmgen.exe和所有的EntityFramework dlls,它仍然没有工作。这个特定的TypeProvider与EntityFramework的一个非常旧的版本绑定在一起,该版本随.NET框架一起提供,不适用于Mono。
我尝试了SQLProvider,它在Mono中编译得很好,但它确实有缺陷,特别是在查询中使用groupby和count。不管怎么说,我放弃了在Mono上操纵这件事。一旦EntityFramework 7发布,我可能会再试一次,因为它将正式支持Mono。
https://stackoverflow.com/questions/30797575
复制相似问题