Try to re-install the Microsoft.EntityFrameworkCore.Tools
package and clear the NuGet Cache:
uninstall Microsoft.EntityFrameworkCore.Tools
package, then go to VS Tools -> Nuget Package Manger -> Package Manager Settings -> General Tab ->Clear All NuGet Cache(s) -> install the Microsoft.EntityFrameworkCore.Tools
package ->Restart Visual Studio.
If still not working, you can try to use the following commands to execute the migration:
dotnet ef migrations add addPerson --context ApplicationDbContext --project Test
dotnet ef database update --context ApplicationDbContext --project Test
The result as below:
and
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Best regards,
Dillion