Database Schema
adamLovettApps edited this page Jun 29, 2021
·
8 revisions
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
username | string | unique, not null |
hashedPassword | string | not null |
string | unique, not null | |
profilePhoto | string | not null |
city | string | not null |
state | string | not null |
zip | int | not null |
bio | text | |
location | geography | not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
userId | int | foreign key, not null |
genreId | int | foreign key, not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
genre | string | unique, not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
userId | int | foreign key, not null |
instrumentId | int | foreign key, not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
instrument | string | unique, not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
userId | int | foreign key, not null |
song | string | not null |
title | string | not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
userId | int | foreign key, not null |
userId2 | int | foreign key, not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
conversationId | int | foreign key, not null |
userIdTo | int | foreign key, not null |
userIdFrom | int | foreign key, not null |
message | string | not null |
Column Name | Data Type | Constraints |
---|---|---|
id | int | primary key, not null |
userId | int | foreign key, not null |
userId2 | int | foreign key, not null |