github.com/readium/readium-lcp-server@v0.0.0-20240509124024-799e77a0bbd6/dbmodel/postgres_db_setup_lcpserver.sql (about) 1 2 CREATE TABLE content ( 3 id varchar(255) PRIMARY KEY NOT NULL, 4 encryption_key bytea NOT NULL, 5 location text NOT NULL, 6 length bigint, 7 sha256 varchar(64), 8 type varchar(255) NOT NULL DEFAULT 'application/epub+zip' 9 ); 10 11 -- SQLINES LICENSE FOR EVALUATION USE ONLY 12 CREATE TABLE license ( 13 id varchar(255) PRIMARY KEY NOT NULL, 14 user_id varchar(255) NOT NULL, 15 provider varchar(255) NOT NULL, 16 issued timestamp(0) NOT NULL, 17 updated timestamp(0) DEFAULT NULL, 18 rights_print int DEFAULT NULL, 19 rights_copy int DEFAULT NULL, 20 rights_start timestamp(0) DEFAULT NULL, 21 rights_end timestamp(0) DEFAULT NULL, 22 content_fk varchar(255) NOT NULL, 23 lsd_status int default 0, 24 FOREIGN KEY(content_fk) REFERENCES content(id) 25 );