diff --git a/gorm_test.go b/gorm_test.go index cbcfbf14..1bc7c682 100644 --- a/gorm_test.go +++ b/gorm_test.go @@ -91,7 +91,7 @@ func init() { // CREATE DATABASE 'gorm'; // GRANT ALL ON gorm.* TO 'gorm'@'localhost'; fmt.Println("testing mysql...") - db, err = Open("mysql", "gorm:gorm@/gorim?charset=utf8&parseTime=True") + db, err = Open("mysql", "gorm:gorm@/gorm?charset=utf8&parseTime=True") case "sqlite": fmt.Println("testing sqlite3...") db, err = Open("sqlite3", "/tmp/gorm.db") diff --git a/main.go b/main.go index 57b31809..cfda79c4 100644 --- a/main.go +++ b/main.go @@ -31,12 +31,6 @@ func (s *DB) DB() *sql.DB { return s.db.(*sql.DB) } -func (s *DB) SetPool(n int) { - if db, ok := s.parent.db.(sqlDb); ok { - db.SetMaxIdleConns(n) - } -} - func (s *DB) SetTagIdentifier(str string) { s.parent.tagIdentifier = str } diff --git a/sql.go b/sql.go index ac781db5..7b02aa66 100644 --- a/sql.go +++ b/sql.go @@ -11,7 +11,6 @@ type sqlCommon interface { type sqlDb interface { Begin() (*sql.Tx, error) - SetMaxIdleConns(n int) } type sqlTx interface {