mirror of
https://github.com/n8n-io/n8n.git
synced 2026-06-01 09:17:08 +02:00
fix(core): Fix getLiveExecutionRowsOnPostgres when there are multiple n8n schemas (#17635)
This commit is contained in:
parent
a415dbfd96
commit
9e3bfff68d
|
|
@ -922,7 +922,7 @@ export class ExecutionRepository extends Repository<ExecutionEntity> {
|
|||
async getLiveExecutionRowsOnPostgres() {
|
||||
const tableName = `${this.globalConfig.database.tablePrefix}execution_entity`;
|
||||
|
||||
const pgSql = `SELECT n_live_tup as result FROM pg_stat_all_tables WHERE relname = '${tableName}';`;
|
||||
const pgSql = `SELECT n_live_tup as result FROM pg_stat_all_tables WHERE relname = '${tableName}' and schemaname = '${this.globalConfig.database.postgresdb.schema}';`;
|
||||
|
||||
try {
|
||||
const rows = (await this.query(pgSql)) as Array<{ result: string }>;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user