Skip to content
Snippets Groups Projects
Commit 325f5609 authored by Andreas Kusalananda Kähäri's avatar Andreas Kusalananda Kähäri
Browse files

Add indexes on synonym.name and on term.name for the benefit of

OntologyTermAdaptor::fetch_by_name().
parent 62b8e507
No related branches found
No related tags found
No related merge requests found
......@@ -42,7 +42,8 @@ CREATE TABLE term (
PRIMARY KEY (term_id),
UNIQUE INDEX accession_idx (accession),
UNIQUE INDEX ontology_acc_idx (ontology_id, accession)
UNIQUE INDEX ontology_acc_idx (ontology_id, accession),
INDEX name_idx (name)
);
CREATE TABLE synonym (
......@@ -51,7 +52,8 @@ CREATE TABLE synonym (
name VARCHAR(255) NOT NULL,
PRIMARY KEY (synonym_id),
UNIQUE INDEX term_synonym_idx (term_id, synonym_id)
UNIQUE INDEX term_synonym_idx (term_id, synonym_id),
INDEX name_idx (name)
);
CREATE TABLE relation_type (
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment