|
|
<h3>All data is stored in the MySQL database</h3>
|
|
|
|
|
|
<h4>ER-model of the database and how the entities are connected to it</h4>
|
|
|
|
|
|
|
|
|
<img src="https://media.discordapp.net/attachments/749996590621524151/836570699346608178/image0.png?width=899&height=676">
|
|
|
|
|
|
|
|
|
|
|
|
**The SQL calls to create the database tables needed:**
|
|
|
|
|
|
```
|
|
|
|
|
|
CREATE TABLE Tasks (
|
|
|
id int NOT NULL PRIMARY KEY AUTO_INCREMENT,
|
|
|
name text NOT NULL,
|
|
|
description text NOT NULL,
|
|
|
priority Boolean NOT NULL,
|
|
|
startDate text NOT NULL,
|
|
|
endDate text NOT NULL,
|
|
|
Completedate text,
|
|
|
categoryId INT NOT NULL
|
|
|
);
|
|
|
|
|
|
|
|
|
CREATE TABLE Categorys (
|
|
|
id int NOT NULL PRIMARY KEY AUTO_INCREMENT,
|
|
|
name text NOT NULL,
|
|
|
description text NOT NULL
|
|
|
);
|
|
|
|
|
|
|
|
|
CREATE TABLE CompletedTasks (
|
|
|
id int NOT NULL PRIMARY KEY AUTO_INCREMENT,
|
|
|
name text NOT NULL,
|
|
|
description text NOT NULL,
|
|
|
priority Boolean NOT NULL,
|
|
|
startDate text NOT NULL,
|
|
|
endDate text NOT NULL,
|
|
|
Completedate text NOT NULL,
|
|
|
categoryId INT NOT NULL
|
|
|
);
|
|
|
```
|
|
|
|
|
|
|