Database Schema - adamLovettApps/solo-project-0521 GitHub Wiki
Users
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| username |
string |
not null, unique |
| email |
string |
not null, unique |
| profilePhotoUrl |
string |
|
| coverPhotoUrl |
string |
|
| email |
string |
not null, unique |
| hashedPassword |
string.binary |
not null |
Photos
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| albumId |
integer |
not null, foreign key |
| userId |
integer |
not null, foreign key |
| url |
string |
not null |
| caption |
string |
|
Albums
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| title |
string |
not null |
| userId |
integer |
not null, foreign key |
Comments
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| userId |
integer |
not null, foreign key |
| body |
string |
not null |
| photoId |
integer |
not null, foreign key |
Favorites
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| userId |
integer |
not null, foriegn key |
| photoId |
integer |
not null, foreign key |
Follows
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| userId |
integer |
not null, foreign key |
| followedId |
integer |
not null, foreign key |
PhotoTags
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| tagId |
integer |
not null, foreign key |
| photoId |
integer |
not null, foreign key |
Tags
| Column Name |
Data Type |
Details |
| id |
integer |
not null, primary key |
| tagname |
string |
not null, unique |
