|
|
@@ -490,7 +490,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 {
|
|
|
@@ -505,7 +506,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
|
|
|
}
|