From 792e76a7742ef02a3297f643d2e4e176d118e720 Mon Sep 17 00:00:00 2001 From: Pranav C <61551451+pranavxc@users.noreply.github.com> Date: Wed, 5 Oct 2022 00:30:52 +0530 Subject: [PATCH] fix(api): oracledb - mm column creation --- .../src/lib/db/sql-client/lib/oracle/OracleClient.ts | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/packages/nocodb/src/lib/db/sql-client/lib/oracle/OracleClient.ts b/packages/nocodb/src/lib/db/sql-client/lib/oracle/OracleClient.ts index 616ee213cd..e7ef13cd00 100644 --- a/packages/nocodb/src/lib/db/sql-client/lib/oracle/OracleClient.ts +++ b/packages/nocodb/src/lib/db/sql-client/lib/oracle/OracleClient.ts @@ -2012,14 +2012,6 @@ class OracleClient extends KnexClient { } alterTableColumn(t, n, o, existingQuery, change = 2) { - // CREATE TABLE test1 ( id integer NOT NULL, title varchar NULL); - - // CREATE TABLE CHINOOK.NEWTABLE_1 ( - // ID INTEGER NOT NULL, - // TITLE VARCHAR(100), - // CONSTRAINT NEWTABLE_1_PK PRIMARY KEY (ID) - // ); - const scale = parseInt(n.dtxs) ? parseInt(n.dtxs) : null; let query = existingQuery ? ',' : ''; @@ -2031,11 +2023,11 @@ class OracleClient extends KnexClient { switch (n.dt) { case 'NUMBER': default: - query += ` ${n.cn} NUMBER `; + query += this.genQuery(` ?? NUMBER `, [n.cn]); break; } } else { - query += ` ${n.cn} ${n.dt}`; + query += this.genQuery(` ?? ${n.dt}`, [n.cn]); } if (!['CLOB', 'NCLOB'].includes(n.dt)) { query += n.dtxp && n.dtxp !== ' ' ? `(${n.dtxp}` : '';