Re: [go-nuts] SQL database connection
I fixed that but I still get errors connecting to the SQL database. Should I deactivate XAMPP before trying it out? On Monday, September 19, 2016 at 12:35:30 PM UTC+3, Harald Weidner wrote: > > Hello, > > On Mon, Sep 19, 2016 at 01:37:14AM -0700, loc...@gmail.com > wrote: > > > import( > > _ "github.com/go-sql-driver" > > ) > > The correct name of this package is: github.com/go-sql-driver/mysql > > Harald > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [go-nuts] SQL database connection
Hello, On Mon, Sep 19, 2016 at 01:37:14AM -0700, loc...@gmail.com wrote: > import( > _ "github.com/go-sql-driver" > ) The correct name of this package is: github.com/go-sql-driver/mysql Harald -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[go-nuts] SQL database connection
What did you expect to see when you ran that code? What did you see instead? -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[go-nuts] SQL database connection
Hello, everyone. I downloaded the SQL-connect driver for GOlang from GitHub and cannot seem to connect to my MYSQL database which was installed along with XAMPP. Below is the code: package main import( "fmt" "database/sql" _ "github.com/go-sql-driver" ) func main(){ mysql, err := sql.Open("mysql", "user:pass@tcp(127.0.0.1)/database") p.DBstatus = mysql == nil mysql.Close() fmt.Println(err) } -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.