首页 > 其他分享 >Your startup project 'UnitTestNet6' doesn't reference Microsoft.EntityFrameworkCore.D

Your startup project 'UnitTestNet6' doesn't reference Microsoft.EntityFrameworkCore.D

时间:2022-11-11 11:46:40浏览次数:48  
标签:reference startup doesn project EntityFrameworkCore Microsoft

执行这个命令

dotnet ef dbcontext scaffold "connection string" Microsoft.EntityFrameworkCore.SqlServer -o ./EntityFrameworkTest/Models -t dbo.Test

 

报错1

Your startup project 'UnitTestNet6' doesn't reference Microsoft.EntityFrameworkCore.Design. This package is required for the Entity Framework Core Tools to work. Ensure your startup project is correct, install the package, and try again.

需要安装Microsoft.EntityFrameworkCore.Tools

 

报错2

Unable to find provider assembly 'Microsoft.EntityFrameworkCore.SqlServer'. Ensure the name is correct and it's referenced by the project.

需要安装Microsoft.EntityFrameworkCore.SqlServer

 

 <PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="6.0.5" />
    <PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="6.0.5">

标签:reference,startup,doesn,project,EntityFrameworkCore,Microsoft
From: https://www.cnblogs.com/chucklu/p/16880048.html

相关文章