drop column ref works

This commit is contained in:
Jan Prochazka
2021-09-05 11:01:52 +02:00
parent 0ef5ac04d8
commit e79e19c614
3 changed files with 17 additions and 10 deletions

View File

@@ -11,6 +11,7 @@ const dialect = {
fallbackDataType: 'varchar',
anonymousPrimaryKey: true,
enableConstraintsPerTable: true,
dropColumnDependencies: ['dependencies'],
quoteIdentifier(s) {
return '"' + s + '"';
},
@@ -40,7 +41,7 @@ const postgresDriverBase = {
__analyserInternals: {
refTableCond: '',
}
},
};
/** @type {import('dbgate-types').EngineDriver} */
@@ -64,12 +65,12 @@ const cockroachDriver = {
dialect: {
...dialect,
materializedViews: true,
dropColumnDependencies: ['primaryKey'],
dropColumnDependencies: ['primaryKey', 'dependencies'],
dropPrimaryKey: false,
},
__analyserInternals: {
refTableCond: 'and fk.referenced_table_name = ref.table_name',
}
},
};
/** @type {import('dbgate-types').EngineDriver} */