mirror of
https://github.com/zhufuyi/sponge.git
synced 2025-10-05 16:57:07 +08:00
fix keyword bug
This commit is contained in:
@@ -15,7 +15,7 @@ func GetMysqlTableInfo(dsn, tableName string) (string, error) {
|
||||
}
|
||||
defer db.Close() //nolint
|
||||
|
||||
rows, err := db.Query("SHOW CREATE TABLE " + tableName)
|
||||
rows, err := db.Query("SHOW CREATE TABLE `" + tableName + "`")
|
||||
if err != nil {
|
||||
return "", fmt.Errorf("query show create table error, %v", err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user