golang mysql 错误 sql: unknown driver “mysql“ (forgotten import?) 解决方法
golang中使用gorm连接mysql的时候会报错:sql: unknown driver "mysql" (forgotten import?)
需要在连接数据库的文件中引入 _ "github.com/jinzhu/gorm/dialects/mysql"
golang中使用gorm连接mysql的时候会报错:sql: unknown driver "mysql" (forgotten import?)
需要在连接数据库的文件中引入 _ "github.com/jinzhu/gorm/dialects/mysql"