Added SQL install file compatible with SQLite for future use, when all queries and PDO connections has been adapted to support this new database

This commit is contained in:
alvarenga.milton 2019-03-03 16:27:59 -03:00
parent 03ae41b78d
commit 6ab45f07ab

View file

@ -0,0 +1,53 @@
--
-- Table structure for table options
--
CREATE TABLE IF NOT EXISTS options (
id INTEGER PRIMARY KEY AUTOINCREMENT,
name CHAR(255) NOT NULL UNIQUE,
value TEXT NOT NULL
);
-- --------------------------------------------------------
--
-- Table structure for table projects
--
CREATE TABLE IF NOT EXISTS projects (
id INTEGER PRIMARY KEY AUTOINCREMENT,
name CHAR(255) NOT NULL,
path CHAR(255) NOT NULL UNIQUE,
owner CHAR(255) NOT NULL UNIQUE,
access text
);
-- --------------------------------------------------------
--
-- Table structure for table users
--
CREATE TABLE IF NOT EXISTS users (
id INTEGER PRIMARY KEY AUTOINCREMENT,
first_name CHAR(255) DEFAULT NULL,
last_name CHAR(255) DEFAULT NULL,
username CHAR(255) NOT NULL UNIQUE,
password text NOT NULL,
email CHAR(255) DEFAULT NULL,
project CHAR(255) DEFAULT NULL,
access CHAR(255) NOT NULL,
groups text,
token text
);
--
-- Table structure for table user_options
--
CREATE TABLE IF NOT EXISTS user_options (
id INTEGER PRIMARY KEY AUTOINCREMENT,
name CHAR(255) NOT NULL UNIQUE,
username CHAR(255) NOT NULL UNIQUE,
value text NOT NULL
);