Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions treebase-core/db/schema/init_db_uptodate.pg
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
\i patches/0003_rename-stepmatrixelement-pk.sql
\i patches/0004_create-indexes.sql
\i patches/0005_add-taxonabel-tb1legacyid.sql
\i patches/0006_add-algorithm-types.sql
\i patches/0007_create-indices.sql



13 changes: 13 additions & 0 deletions treebase-core/db/schema/patches/0006_add-algorithm-types.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
insert into versionhistory(patchnumber, patchlabel, patchdescription)
values (6, 'add-algorithm-types',
'Add standard algorithm types reference data');

delete from algorithm;
insert into algorithm (type, algorithm_id, version, description) values
('L', 1, 1, 'maximum likelihood'),
('B', 2, 1, 'bayesian inference'),
('P', 3, 1, 'parsimony'),
('E', 4, 1, 'minimum evolution'),
('J', 5, 1, 'neighbor joining'),
('U', 6, 1, 'UPGMA');

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
insert into versionhistory(patchnumber, patchlabel, patchdescription)
values (6, 'create-indices',
'Create additional indices to improve query performance.');
values (7, 'create-indices',
'Create additional indices to improve query performance');

CREATE INDEX discretecharstate_phylochar_id_idx ON discretecharstate USING btree (phylochar_id);
CREATE INDEX matrixcolumn_matrix_id_idx ON matrixcolumn USING btree (matrix_id);
Expand Down
12 changes: 12 additions & 0 deletions treebase-core/src/main/resources/initTreebase.sql
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,18 @@ alter table study alter column study_id restart with 2;
commit;
-- END Study, StudyStatus, Submission

-- Add algorithm reference data
delete from algorithm;
insert into algorithm (type, algorithm_id, version, description) values
('L', 1, 1, 'maximum likelihood'),
('B', 2, 1, 'bayesian inference'),
('P', 3, 1, 'parsimony'),
('E', 4, 1, 'minimum evolution'),
('J', 5, 1, 'neighbor joining'),
('U', 6, 1, 'UPGMA');
alter table algorithm alter column algorithm_id restart with 7;
commit;

-- Add indices
--CREATE INDEX "TREENODE_TREE_IDX"
-- ON "PHYLOTREENODE"("PHYLOTREE_ID")
Expand Down
Loading