schema.sql 989 B

12345678910111213141516171819202122232425262728293031323334353637
  1. drop table if exists epube_pagination;
  2. drop table if exists epube_books;
  3. drop table if exists epube_users;
  4. drop table if exists epube_sessions;
  5. drop index if exists epube_sessions_expire;
  6. create table epube_pagination(
  7. id integer not null primary key autoincrement,
  8. bookid integer not null,
  9. total_pages integer not null,
  10. pagination text not null);
  11. create table epube_books(
  12. id integer not null primary key autoincrement,
  13. bookid integer not null,
  14. owner varchar(200) not null,
  15. lastcfi varchar(200) not null,
  16. lastread integer not null);
  17. create table epube_users(
  18. id integer not null primary key autoincrement,
  19. user varchar(100) not null,
  20. pass varchar(200) not null);
  21. create table epube_sessions (
  22. id varchar(250) not null primary key,
  23. data text,
  24. expire integer not null);
  25. create table epube_favorites(
  26. id integer not null primary key autoincrement,
  27. bookid integer not null,
  28. owner varchar(200) not null);
  29. create index epube_sessions_expire on epube_sessions(expire);