.NET Core 8/ Blazor 问题:无法创建实体框架迁移

问题描述 投票:0回答:1

当尝试使用

dotnet ef migrations add Initial
命令为我的项目创建迁移时,我遇到了以下错误
dotnet : You must install or update .NET to run this application.

这个问题的解决方案是什么?将 Entity Framework 降级到版本 5.0.5 并重新安装 dotnet-ef 工具不起作用。

asp.net entity-framework asp.net-core entity-framework-migrations
1个回答
0
投票

您可以使用

检查您的 .net 运行时
dotnet --list-runtimes

确保您已安装 .net8 的运行时

您可以在此处下载运行时:https://dotnet.microsoft.com/en-us/download/dotnet/8.0

© www.soinside.com 2019 - 2024. All rights reserved.