Adding library table.
This commit is contained in:
parent
a8d812495a
commit
ad4c747aea
1 changed files with 10 additions and 0 deletions
10
migrations/sqlite/0004_library.sql
Normal file
10
migrations/sqlite/0004_library.sql
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
create table library_books (
|
||||
id integer primary key autoincrement,
|
||||
isbn integer default 0 not null,
|
||||
-- ISBN-10 check digit. If it is the maximum allowable value in the base-11 format (i.e. the ISBN-10 ends with "X") this will be "1".
|
||||
isbn_check integer default 0 not null,
|
||||
title text default '' not null,
|
||||
authors text default '' not null,
|
||||
meta jsonb default '{}' not null
|
||||
);
|
||||
create unique index library_books_isbn_check_idx on library_books(isbn, isbn_check);
|
||||
Loading…
Reference in a new issue