Skip to content
jdarmoni edited this page Mar 28, 2019 · 9 revisions

users

Column Name data type details
id integer not null
username string not null
email string not null
password_digest string not null
session_token string not null
timestamps string not null
bookshelf_ids array not null

index on username, unique: true

index on session_token, unique: true

book

Column Name data type details
title string not null
description string not null
author_string string not null
timestamps string not null
published_date integer allow null
pages integer allow null

shelvings

Column Name data type details
book_id integer not null
bookshelf_id integer not null
timestamp string not null

comments

Column Name data type details
content string not null
author_id integer not null
book_id integer not null
timestamp string not null
review_id integer not null

index on author_id

author_id references users

reviews

Column Name data type details
content string allow null
author_id integer not null
timestamp string not null
book_id integer not null
rating integer allow null

author_id references users

index on author_id

bookshelf

Column Name data type details
title string not null
book_id integer not null
name string not null
description string not null
timestamp string not null

Clone this wiki locally