-fix ancestries schema for sources

merge-requests/22/head
James Miller 2019-08-08 17:30:13 -05:00
parent bc28d239e2
commit 92e51a2d08
2 changed files with 5 additions and 2 deletions

View File

@ -10,6 +10,8 @@ table that matches feats to ancestries, etc..
CREATE TABLE ancestries (
ancestry_id INTEGER PRIMARY KEY,
sources_id INTEGER NOT NULL,
sources_pages TEXT,
short_name TEXT NOT NULL UNIQUE,
flavor_text TEXT NOT NULL,
hp INTEGER NOT NULL,

View File

@ -27,6 +27,8 @@ CREATE TABLE spellschools (
CREATE TABLE spells (
spells_id INTEGER PRIMARY KEY,
sources_id INTEGER NOT NULL,
sources_pages TEXT,
nethysurl TEXT,
name TEXT NOT NULL UNIQUE,
source TEXT,
@ -38,8 +40,7 @@ CREATE TABLE spells (
range_text TEXT,
range_ft INTEGER,
targets TEXT,
FOREIGN KEY (sources_id) REFERENCES sources(sources_id)
FOREIGN KEY (sources_id) REFERENCES sources(sources_id),
FOREIGN KEY (spelltypes_id) REFERENCES spelltypes(spelltypes_id)
);