From ebdcd9ad941a68df5343b0810fc900b3e7263a88 Mon Sep 17 00:00:00 2001 From: Jan Prochazka Date: Fri, 31 May 2024 16:49:43 +0200 Subject: [PATCH] oracle: detect autoincrement column --- .../src/backend/Analyser.js | 20 +------------------ 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/plugins/dbgate-plugin-oracle/src/backend/Analyser.js b/plugins/dbgate-plugin-oracle/src/backend/Analyser.js index 07b45835..9adfa279 100644 --- a/plugins/dbgate-plugin-oracle/src/backend/Analyser.js +++ b/plugins/dbgate-plugin-oracle/src/backend/Analyser.js @@ -22,25 +22,7 @@ function getColumnInfo( if (char_max_length && isTypeString(normDataType)) fullDataType = `${normDataType}(${char_max_length})`; if (numeric_precision && numeric_ccale && isTypeNumeric(normDataType)) fullDataType = `${normDataType}(${numeric_precision},${numeric_ccale})`; - const autoIncrement = !!(default_value && default_value.startsWith('nextval(')); - if ( - table && - geometryColumns && - geometryColumns.rows.find( - x => x.schema_name == table.schemaName && x.pure_name == table.pureName && x.column_name == column_name - ) - ) { - fullDataType = 'geometry'; - } - if ( - table && - geographyColumns && - geographyColumns.rows.find( - x => x.schema_name == table.schemaName && x.pure_name == table.pureName && x.column_name == column_name - ) - ) { - fullDataType = 'geography'; - } + const autoIncrement = !!(default_value && default_value.endsWith('.nextval')); return { columnName: column_name, dataType: fullDataType,