【数据库连接】连接sqlite3报错:go-sqlite3 requires cgo to work. This is a stub

报错信息

powershell 复制代码
register db Ping default, Binary was compiled with 'CGO_ENABLED=0', go-sqlite3 requires cgo to work. This is a stub

Windows解决办法

新建环境变量

新报错

powershell 复制代码
Failed to build the application: # runtime/cgo
cgo: C compiler "gcc" not found: exec: "gcc": executable file not found in %PATH%

安装GCC

官网:https://gitcode.com/mattn/go-sqlite3/tree/master?utm_source=csdn_github_accelerator\&isLogin=1

下载

安装



这样就可以解决了!

相关推荐
m0_71643007几秒前
mysql数据量过亿时索引如何优化_mysql分库分表索引设计
jvm·数据库·python
Chasing__Dreams1 分钟前
Mysql--基础知识点--101--在线扩容
数据库·mysql
Shorasul1 分钟前
c++如何利用C++23的std--expected重构传统的文件IO报错代码【进阶】
jvm·数据库·python
bilI LESS2 分钟前
数据库操作与数据管理——Rust 与 SQLite 的集成
数据库·rust·sqlite
m0_748920363 分钟前
HTML函数开发需要多少瓦电源_整机功耗估算指南【说明】
jvm·数据库·python
m0_746752303 分钟前
C#怎么使用Tuple元组返回多个值_C#如何简化方法返回值【基础】
jvm·数据库·python
qq_654366984 分钟前
如何处理ORA-01658报错_无法为表空间中的段创建INITIAL区
jvm·数据库·python
黑牛儿5 分钟前
Swoole协程 vs Go协程:PHP开发者一看就懂的实战对比
后端·golang·php·swoole
weixin_408717775 分钟前
Python Tkinter自定义对话框怎么写_Toplevel创建子窗口并结合wait_window()实现阻塞
jvm·数据库·python
2301_817672265 分钟前
HTML5中LocalStorage存储敏感数据的加密脱敏处理
jvm·数据库·python