mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-18 14:56:01 +00:00
18 lines
443 B
JavaScript
18 lines
443 B
JavaScript
const { SqlDumper, arrayToHexString } = global.DBGATE_TOOLS;
|
|
|
|
class Dumper extends SqlDumper {
|
|
renameColumn(column, newcol) {
|
|
this.putCmd('^alter ^table %f ^rename ^column %i ^to %i', column, column.columnName, newcol);
|
|
}
|
|
|
|
renameTable(obj, newname) {
|
|
this.putCmd('^alter ^table %f ^rename ^to %i', obj, newname);
|
|
}
|
|
|
|
putByteArrayValue(value) {
|
|
this.putRaw(`x'${arrayToHexString(value)}'`);
|
|
}
|
|
}
|
|
|
|
module.exports = Dumper;
|