-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathschema.txt
72 lines (60 loc) · 1.61 KB
/
schema.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
/*
CREATE TABLE indi(
INDI varchar(10) NOT NULL,
LNAME varchar(30) ,
FNAME varchar(60) ,
TITLE varchar(20) ,
LNAME_MP varchar(4) ,
FAMC varchar(10) ,
SEX char(1) ,
REFN varchar(20) ,
NOTE varchar(10) ,
PRIMARY KEY (INDI));
CREATE TABLE child(
FAMI varchar(10) NOT NULL,
SEQ integer PRIMARY KEY,
INDI varchar(10) NOT NULL);
CREATE TABLE fami(
FAMI varchar(10) NOT NULL,
HUSB varchar(10),
WIFE varchar(10),
NOTE varchar(10),
PRIMARY KEY (FAMI));
CREATE TABLE fams(
INDI varchar(10) NOT NULL,
SEQ integer PRIMARY KEY,
FAMI varchar(10) NOT NULL);
CREATE TABLE notes(
NOTE varchar(10) NOT NULL,
SEQ integer PRIMARY KEY,
TEXT varchar(255));
CREATE TABLE sour(
SOUR varchar(10) NOT NULL,
TITL varchar(255),
AUTH varchar(255),
PUBL varchar(1024),
REPO varchar(255),
PRIMARY KEY (SOUR));
CREATE TABLE events(
REFID varchar(10) NOT NULL,
SEQ integer PRIMARY KEY,
ETYPE varchar(30) NOT NULL,
DATE varchar(50),
PLAC varchar(255),
NOTE varchar(10),
TEXT varchar(255));
CREATE TABLE sourtxt(
REFID varchar(10) NOT NULL,
SEQ integer PRIMARY KEY,
SOURID varchar(10),
TEXT varchar(255));
CREATE INDEX indi_idx on child (indi);
CREATE INDEX wife_idx on fami (wife);
CREATE INDEX husb_idx on fami (husb);
CREATE INDEX fami_idx on fams (fami);
CREATE INDEX child_idx on child (fami, seq);
CREATE INDEX fams_idx on fams (indi, seq);
CREATE INDEX notes_idx on notes (note, seq);
CREATE INDEX events_refid_idx on sourtxt (refid, seq);
CREATE INDEX sourtxt_refid_idx on sourtxt (refid, seq);
*/