From 83ddb9c8dde1f8b5f4ea13e3bde1dc637ddb6002 Mon Sep 17 00:00:00 2001 From: mike12345567 Date: Mon, 22 May 2023 14:28:18 +0100 Subject: [PATCH] Adding feature to denote fetch table names function. --- packages/server/src/integrations/googlesheets.ts | 7 +++++-- packages/server/src/integrations/microsoftSqlServer.ts | 5 ++++- packages/server/src/integrations/mysql.ts | 5 ++++- packages/server/src/integrations/oracle.ts | 5 ++++- packages/server/src/integrations/postgres.ts | 5 ++++- packages/types/src/sdk/datasources.ts | 1 + 6 files changed, 22 insertions(+), 6 deletions(-) diff --git a/packages/server/src/integrations/googlesheets.ts b/packages/server/src/integrations/googlesheets.ts index 0a5d2acefc..e965ebc86c 100644 --- a/packages/server/src/integrations/googlesheets.ts +++ b/packages/server/src/integrations/googlesheets.ts @@ -63,10 +63,13 @@ const SCHEMA: Integration = { relationships: false, docs: "https://developers.google.com/sheets/api/quickstart/nodejs", description: - "Create and collaborate on online spreadsheets in real-time and from any device. ", + "Create and collaborate on online spreadsheets in real-time and from any device.", friendlyName: "Google Sheets", type: "Spreadsheet", - features: [DatasourceFeature.CONNECTION_CHECKING], + features: [ + DatasourceFeature.CONNECTION_CHECKING, + DatasourceFeature.FETCH_TABLE_NAMES, + ], datasource: { spreadsheetId: { display: "Google Sheet URL", diff --git a/packages/server/src/integrations/microsoftSqlServer.ts b/packages/server/src/integrations/microsoftSqlServer.ts index ab0a3e14e8..a83630afbb 100644 --- a/packages/server/src/integrations/microsoftSqlServer.ts +++ b/packages/server/src/integrations/microsoftSqlServer.ts @@ -40,7 +40,10 @@ const SCHEMA: Integration = { "Microsoft SQL Server is a relational database management system developed by Microsoft. ", friendlyName: "MS SQL Server", type: "Relational", - features: [DatasourceFeature.CONNECTION_CHECKING], + features: [ + DatasourceFeature.CONNECTION_CHECKING, + DatasourceFeature.FETCH_TABLE_NAMES, + ], datasource: { user: { type: DatasourceFieldType.STRING, diff --git a/packages/server/src/integrations/mysql.ts b/packages/server/src/integrations/mysql.ts index ca0c962d25..d83ce300d3 100644 --- a/packages/server/src/integrations/mysql.ts +++ b/packages/server/src/integrations/mysql.ts @@ -36,7 +36,10 @@ const SCHEMA: Integration = { type: "Relational", description: "MySQL Database Service is a fully managed database service to deploy cloud-native applications. ", - features: [DatasourceFeature.CONNECTION_CHECKING], + features: [ + DatasourceFeature.CONNECTION_CHECKING, + DatasourceFeature.FETCH_TABLE_NAMES, + ], datasource: { host: { type: DatasourceFieldType.STRING, diff --git a/packages/server/src/integrations/oracle.ts b/packages/server/src/integrations/oracle.ts index 53e88752cd..55b425f480 100644 --- a/packages/server/src/integrations/oracle.ts +++ b/packages/server/src/integrations/oracle.ts @@ -50,7 +50,10 @@ const SCHEMA: Integration = { type: "Relational", description: "Oracle Database is an object-relational database management system developed by Oracle Corporation", - features: [DatasourceFeature.CONNECTION_CHECKING], + features: [ + DatasourceFeature.CONNECTION_CHECKING, + DatasourceFeature.FETCH_TABLE_NAMES, + ], datasource: { host: { type: DatasourceFieldType.STRING, diff --git a/packages/server/src/integrations/postgres.ts b/packages/server/src/integrations/postgres.ts index 0954f94ecb..d8385705f1 100644 --- a/packages/server/src/integrations/postgres.ts +++ b/packages/server/src/integrations/postgres.ts @@ -52,7 +52,10 @@ const SCHEMA: Integration = { type: "Relational", description: "PostgreSQL, also known as Postgres, is a free and open-source relational database management system emphasizing extensibility and SQL compliance.", - features: [DatasourceFeature.CONNECTION_CHECKING], + features: [ + DatasourceFeature.CONNECTION_CHECKING, + DatasourceFeature.FETCH_TABLE_NAMES, + ], datasource: { host: { type: DatasourceFieldType.STRING, diff --git a/packages/types/src/sdk/datasources.ts b/packages/types/src/sdk/datasources.ts index 4631a091b4..24ccea7e83 100644 --- a/packages/types/src/sdk/datasources.ts +++ b/packages/types/src/sdk/datasources.ts @@ -75,6 +75,7 @@ export enum FilterType { export enum DatasourceFeature { CONNECTION_CHECKING = "connection", + FETCH_TABLE_NAMES = "fetch_table_names", } export interface StepDefinition {