update the go-sql-driver upper to lower fix #351

This commit is contained in:
astaxie
2014-08-31 00:31:33 +08:00
parent bfb8dcaff3
commit 6ba5a5fcef

View File

@@ -37,7 +37,7 @@ Go中支持MySQL的驱动目前比较多有如下几种有些是支持data
package main
import (
_ "github.com/Go-SQL-Driver/MySQL"
_ "github.com/go-sql-driver/mysql"
"database/sql"
"fmt"
//"time"
@@ -114,7 +114,7 @@ Go中支持MySQL的驱动目前比较多有如下几种有些是支持data
关键的几个函数我解释一下:
sql.Open()函数用来打开一个注册过的数据库驱动,Go-MySQL-Driver中注册了mysql这个数据库驱动第二个参数是DSN(Data Source Name),它是Go-MySQL-Driver定义的一些数据库链接和配置信息。它支持如下格式
sql.Open()函数用来打开一个注册过的数据库驱动,go-sql-driver中注册了mysql这个数据库驱动第二个参数是DSN(Data Source Name),它是go-sql-driver定义的一些数据库链接和配置信息。它支持如下格式
user@unix(/path/to/socket)/dbname?charset=utf8
user:password@tcp(localhost:5555)/dbname?charset=utf8