-
Notifications
You must be signed in to change notification settings - Fork 1
Database Schema
Walter Hills edited this page Mar 19, 2021
·
7 revisions

| column name | data type | details |
|---|---|---|
id |
serial | not null, primary key |
firstName |
varchar(25) | not null |
lastName |
varchar(25) | not null |
email |
varchar(255) | not null, unique |
hashedPassword |
binary | not null |
-
UsershasManyNotebooksassociation
| column name | data type | details |
|---|---|---|
id |
serial | not null, primary key |
name |
varchar(55) | not null, unique |
user_id |
integer | not null, foreign key |
-
NotebooksbelongsToUsersassociation
| column name | data type | details |
|---|---|---|
id |
serial | not null, primary key |
text |
text | not null |
title |
text | not null |
notebook_id |
integer | not null, foreign key |
-
NoteshasManyNotesToTagsassociation -
NotesbelongsToNotebooksassociation
| column name | data type | details |
|---|---|---|
id |
serial | not null, primary key |
note_id |
integer | not null, foreign key |
tag_id |
integer | not null, foreign key |
-
NotesToTagsbelongsToNotesassociation -
NotesToTagsbelongsToTagsassociation
| column name | data type | details |
|---|---|---|
id |
serial | not null, primary key |
tag |
varchar(255) | not null |
-
TagshasManyNotesToTagsassociation