mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-18 06:46:00 +00:00
using GO separator for MS SQL db sync
This commit is contained in:
@@ -1,6 +1,21 @@
|
||||
const { SqlDumper, testEqualColumns } = global.DBGATE_TOOLS;
|
||||
|
||||
class MsSqlDumper extends SqlDumper {
|
||||
constructor(driver, options) {
|
||||
super(driver);
|
||||
if (options && options.useHardSeparator) {
|
||||
this.useHardSeparator = true;
|
||||
}
|
||||
}
|
||||
|
||||
endCommand() {
|
||||
if (this.useHardSeparator) {
|
||||
this.putRaw('\nGO\n');
|
||||
} else {
|
||||
super.endCommand();
|
||||
}
|
||||
}
|
||||
|
||||
autoIncrement() {
|
||||
this.put(' ^identity');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user