有没有办法在运行Scaffold-DbContext
命令时排除表?
我试过像
这样的东西Scaffold-DbContext -provider EntityFramework.MicrosoftSqlServer
-connection "xxx" -OutputDirectory Models
-Tables "dbo.a,dbo.b,dbo.c,dbo.d"
但我得到Build failed
答案 0 :(得分:2)
Tables参数接受单维字符串数组,您只需将其更改为数组格式:
"dbo.a", "dbo.b", "dbo.c"
谢谢面包!