「golang」panic: commands out of sync. Did you run multiple
发布时间:2020-12-16 09:30:57 所属栏目:大数据 来源:网络整理
导读:【问题现象】 go使用 go-sql-driver 连接mariaDB,如下,提示: panic: commands out of sync. Did you run multiple statements at once ? 示例: func NewMysqlDB(host string ,port int ,user ,pwd ,dbName string ,maxIdle int) (*sqlx. DB , error) { s
【问题现象】 go使用go-sql-driver连接mariaDB,如下,提示: panic: commands out of sync. Did you run multiple statements at once ? 示例: func NewMysqlDB(host string,port int,user,pwd,dbName string,maxIdle int) (*sqlx.DB,error) {
【问题解决】 这个提示很是误导了我,实际上,问题原因是port填错了,坑! (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |