Excluding tables with database first approach

c# entity-framework entity-framework-core

Question

Is there a way to exclude tables when running the Scaffold-DbContext command?

I tried something like

Scaffold-DbContext -provider EntityFramework.MicrosoftSqlServer 
       -connection "xxx" -OutputDirectory Models 
       -Tables "dbo.a,dbo.b,dbo.c,dbo.d"

but I get Build failed

1
5
3/29/2016 4:42:27 AM

Accepted Answer

The Tables parameter accepts single dimensional string array, you just need to change it to array format:

"dbo.a", "dbo.b", "dbo.c"

Thanks Bread!

3
3/29/2016 2:20:35 AM


Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow