-
Notifications
You must be signed in to change notification settings - Fork 0
Schema
Zalkifl Syed edited this page Apr 21, 2019
·
1 revision
Database Schema
| column name | data type | details |
|---|---|---|
id |
integer | not null, primary_key
|
username |
string | not null, unique, indexed |
email |
string | not null, unique, indexed |
password_digest |
string | not null |
session_token |
string | not null |
- index on
[username], unique: true - index on
[email], unique: true -
has_manytasks, lists, catagories.
| column name | data type | details |
|---|---|---|
id |
integer | not null, primary_key
|
work |
boolean | default: false |
exercise |
boolean | default: false |
garden |
boolean | default: false |
groceries |
boolean | default: false |
user_id |
integer |
foreign_key, not null, indexed |
-
user_idreferencesuser - index on
[user_id]
| column name | data type | details |
|---|---|---|
id |
integer | not null, primary_key
|
name |
string | not null, indexed |
catagory |
string | not null |
closed |
boolean | default: false |
user_id |
integer | not null, foreign_key
|
- be able to map location, to keep track where each split occurred.
- index on
[name] - index on
[longitude, latitude]
| column name | data type | details |
|---|---|---|
id |
integer | not null, primary_key
|
description |
string | not null |
user_id |
integer | not null, indexed, foreign_key
|
list_id |
integer | not null, indexed, foreign_key
|
complete |
boolean | default: false |
-
user_idreferencesuser -
list_idreferenceslist - index on
[list_id, user_id]