如何通过edmgen工具只生成objectLayer,而不生成csdl、ssdl和视图?
"%windir%\Microsoft.NET\Framework\v4.0.30319\edmgen.exe“/mode:fullgeneration /c:"Data Source=.\sqlexpress;Initial Catalog=uqs;IntegratedSecurity=SSPI”/project:generateEntityModel /entitycontainer:uqsEntities /namespace:uqsModel /language:CSharp /outobjectlayer:"D:/uqsObjectLayer.cs“
在这个脚本中,我不写位置来编写csdl、ssdl和视图,但是它们是在windows中的C:\Users\adminUser中生成的,而objectLayer是在D:/uqsObjectLayer.cs.中生成的如果我使用/mode:EntityClassGeneration,this option requires the /incsdl argument and either the /project argument or the /outobjectlayer argument. The /language argument is optional.
但我不想使用csdl文件。据我所知,edmgen.tool不能在没有csdl文件的情况下创建对象层。现在有其他方法或工具从db生成对象层吗?
发布于 2010-04-26 15:53:08
模式:EntityClassGeneration不生成CSDL;它读取它。如果不读取CSDL,就无法生成源代码(但请注意,CSDL可以是EDMX文件的一部分)。
https://stackoverflow.com/questions/2708134
复制相似问题