I am new to .Net Core and I'd like to know scaffold EF support sql view like it supports sql table in .Net Core 6? If it supports which command will do? For tables,Scaffold-DbContext and is it same command?
Thank you very much in advance!
I am new to .Net Core and I'd like to know scaffold EF support sql view like it supports sql table in .Net Core 6? If it supports which command will do? For tables,Scaffold-DbContext and is it same command?
Thank you very much in advance!
Scaffold-DbContext can scaffold both tables and views, Here is the Example:-
Scaffold-DbContext "Server=10.10.10.123;Database=Testdb; user id=sa; password=Sa1234" Microsoft.EntityFrameworkCore.SqlServer -OutputDir Models -Context TestDBContext -Tables v_employee