How to fix error — “dotnet : No executable found matching command “dotnet-ef”’

Entity Framework Core 2.0 + Visual Studio 2017 IDE + DotNet CLI

While setting up new .NET Core Web API 2.0 projects with EF Core 2.0, you may encounter this error: “dotnet : No executable found matching command “dotnet-ef” when you try to add initial migration or running command dotnet ef database update from Visual Studio 2017 IDE.

In Google search you will find solutions to update your .csproj files with matching NuGet EF Core packages versions.

If your issue is not resolved by version update and you are running command in Visual Studio’s Package manager console then make sure your current working directory contains .csproj file. When you start Package Manager console inside VS 2017, it set current working directory with solution folder. So you must go to one level deep where .csproj file is present and then run dotnet ef database update command.


Cloud Solution Architect | Author | Full Stack Developer | |

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store