.netcore 打开SQLite数据库失败:You need to call SQLitePCL.raw.SetProvider(). If you are using a bundle package, this is done by calling SQLitePCL.Batteries.Init().”


.net core打开SQLite数据库时发生错误,错误信息如下:

You need to call SQLitePCL.raw.SetProvider().  If you are using a bundle package, this is done by calling SQLitePCL.Batteries.Init().”

解决方案

检查nuget引用,是不是引用了 Microsoft.Data.Sqlite.Core 替换为  Microsoft.Data.Sqlite 解决

替换后 

 

版权声明:本文为YES开发框架网发布内容,转载请附上原文出处连接
YES开发框架
上一篇:.net core使用Microsoft.Data.Sqlite创建SQLite数据库文件
下一篇:.netcore 打开SQLite数据库失败:You need to call SQLitePCL.raw.SetProvider(). If you are using a bundle package, this is done by calling SQLitePCL.Batteries.Init().”
评论列表

发表评论

评论内容
昵称:

联系我们
联系电话:15090125178(微信同号)
电子邮箱:garson_zhang@163.com
站长微信二维码
微信二维码