diff --git a/packages/server/src/integrations/postgres.ts b/packages/server/src/integrations/postgres.ts index a3e49687b6..220f35dae5 100644 --- a/packages/server/src/integrations/postgres.ts +++ b/packages/server/src/integrations/postgres.ts @@ -208,6 +208,7 @@ module PostgresModule { */ async buildSchema(datasourceId: string, entities: Record) { let tableKeys: { [key: string]: string[] } = {} + await this.openConnection() try { const primaryKeysResponse = await this.client.query( this.PRIMARY_KEYS_SQL