我有一个 WCF 项目,它可以使用 AZURE SQL CONNECTION 在本地完美运行。但是当我在 Azure 上部署 WCF 项目时,它将开始出现此错误。
在没有部署的情况下测试 WCF
测试部署的 WCF
这是我最近发布的一篇文章,但尚未成功给出答案,但描述了我的场景的一些细节。我越来越绝望了,我花了一整天的时间试图解决这个问题
Why does throws me a FaultException in WCF Service?
我错过了什么?
最佳答案
Once you are using model-first / database-first (EDMX) you must use Entity connection string with referencing .ssdl, .msl and .csdl metadata files. Also be aware that you must create your database in design time when creating model from EDMX = you must generate SQL script and execute it to create the database.
欲了解更多信息,请查看Answered by Ladislav Mrnka和 Code First vs. Database First
希望这对您有帮助。
关于c# - 为什么 Entity Framework 可以在本地工作但不能在 azure 上工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14543514/