Does a Go Mysql driver exist that supports multiple statements within a single string?

前端 未结 5 2109
生来不讨喜
生来不讨喜 2020-12-18 04:44

I\'m trying to find a MySql driver that i can use with Go which supports issuing multiple SQL statements in one call. For example i might wish to create a database using the

5条回答
  •  醉梦人生
    2020-12-18 05:01

    the github.com/go-sql-driver/mysql can be configured to accept multiple statements with the multiStatements=true connection parameter.

    The documentation clearly states why you should be careful doing it. See https://github.com/go-sql-driver/mysql

提交回复
热议问题