parent
dd13327382
commit
31aa00fa4b
4 changed files with 11 additions and 6 deletions
5
vendor/github.com/go-xorm/xorm/engine.go
generated
vendored
5
vendor/github.com/go-xorm/xorm/engine.go
generated
vendored
|
@ -481,7 +481,8 @@ func (engine *Engine) dumpTables(tables []*core.Table, w io.Writer, tp ...core.D
|
|||
}
|
||||
|
||||
cols := table.ColumnsSeq()
|
||||
colNames := dialect.Quote(strings.Join(cols, dialect.Quote(", ")))
|
||||
colNames := engine.dialect.Quote(strings.Join(cols, engine.dialect.Quote(", ")))
|
||||
destColNames := dialect.Quote(strings.Join(cols, dialect.Quote(", ")))
|
||||
|
||||
rows, err := engine.DB().Query("SELECT " + colNames + " FROM " + engine.Quote(table.Name))
|
||||
if err != nil {
|
||||
|
@ -496,7 +497,7 @@ func (engine *Engine) dumpTables(tables []*core.Table, w io.Writer, tp ...core.D
|
|||
return err
|
||||
}
|
||||
|
||||
_, err = io.WriteString(w, "INSERT INTO "+dialect.Quote(table.Name)+" ("+colNames+") VALUES (")
|
||||
_, err = io.WriteString(w, "INSERT INTO "+dialect.Quote(table.Name)+" ("+destColNames+") VALUES (")
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue