refactor(core): Add support for implicit schema in postgres migrations (#5233)
This commit is contained in:
committed by
GitHub
parent
726b573eab
commit
a86c9a628b
@@ -91,16 +91,7 @@ export async function runInBatches(
|
||||
} while (batchedQueryResults.length === limit);
|
||||
}
|
||||
|
||||
export const getTablePrefix = () => {
|
||||
const tablePrefix = config.getEnv('database.tablePrefix');
|
||||
|
||||
if (config.getEnv('database.type') === 'postgresdb') {
|
||||
const schema = config.getEnv('database.postgresdb.schema');
|
||||
return [schema, tablePrefix].join('.');
|
||||
}
|
||||
|
||||
return tablePrefix;
|
||||
};
|
||||
export const getTablePrefix = () => config.getEnv('database.tablePrefix');
|
||||
|
||||
export const escapeQuery = (
|
||||
queryRunner: QueryRunner,
|
||||
|
||||
Reference in New Issue
Block a user