From 6ea5a2785b4077ca8f7b7af558a926d90e37f96c Mon Sep 17 00:00:00 2001 From: Neha Verma Date: Mon, 18 Nov 2024 20:24:07 +0530 Subject: [PATCH] Update schema.sql Updated schema as per postgres SQL DB --- starter/cloudstorage/src/main/resources/schema.sql | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/starter/cloudstorage/src/main/resources/schema.sql b/starter/cloudstorage/src/main/resources/schema.sql index 2d91bdc39..f8c15144f 100644 --- a/starter/cloudstorage/src/main/resources/schema.sql +++ b/starter/cloudstorage/src/main/resources/schema.sql @@ -1,5 +1,5 @@ CREATE TABLE IF NOT EXISTS USERS ( - userid INT PRIMARY KEY auto_increment, + userid serial PRIMARY KEY, username VARCHAR(20) UNIQUE, salt VARCHAR, password VARCHAR, @@ -8,7 +8,7 @@ CREATE TABLE IF NOT EXISTS USERS ( ); CREATE TABLE IF NOT EXISTS NOTES ( - noteid INT PRIMARY KEY auto_increment, + noteid serial PRIMARY KEY, notetitle VARCHAR(20), notedescription VARCHAR (1000), userid INT, @@ -16,7 +16,7 @@ CREATE TABLE IF NOT EXISTS NOTES ( ); CREATE TABLE IF NOT EXISTS FILES ( - fileId INT PRIMARY KEY auto_increment, + fileId serial PRIMARY KEY, filename VARCHAR, contenttype VARCHAR, filesize VARCHAR, @@ -26,7 +26,7 @@ CREATE TABLE IF NOT EXISTS FILES ( ); CREATE TABLE IF NOT EXISTS CREDENTIALS ( - credentialid INT PRIMARY KEY auto_increment, + credentialid serial PRIMARY KEY, url VARCHAR(100), username VARCHAR (30), key VARCHAR,