Scaffold-DbContext "Server=localhost;Database=HjwTestDB;User ID=postgres;Password=111111;Pooling=true;" Npgsql.EntityFrameworkCore.PostgreSQL -OutputDir DataTemp
Scaffold-DbContext “Server=.; Database=AppsDBFarm;Persist Security Info=True;User ID = sa; password=123456;” Microsoft.EntityFrameworkCore.SqlServer -OutputDir Models
驱动不同引用不同。先生成model之后再用tt文件生成repository