-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #439 from EBISPOT/goci#166_split_and_index_bg_traits
Goci#166 split and index bg traits
- Loading branch information
Showing
18 changed files
with
202 additions
and
8 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
...ci-db-binding/src/main/resources/db/migration/V2.7_0_002__Add_background_associations.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
/* | ||
################################################################################ | ||
Migration script to create table ASSOCIATION_BKG_EFO_TRAIT and its constraints | ||
author: Ala Abid | ||
date: 07 jun 2021 | ||
version: 2.7.0.002 | ||
################################################################################ | ||
*/ | ||
|
||
-------------------------------------------------------- | ||
-- CREATE TABLE, INDEX, FOREIGN KEY | ||
-------------------------------------------------------- | ||
|
||
CREATE TABLE ASSOCIATION_BKG_EFO_TRAIT (ASSOCIATION_ID NUMBER(19,0), EFO_TRAIT_ID NUMBER(19,0)); | ||
ALTER TABLE ASSOCIATION_BKG_EFO_TRAIT MODIFY (EFO_TRAIT_ID NOT NULL); | ||
ALTER TABLE ASSOCIATION_BKG_EFO_TRAIT MODIFY (ASSOCIATION_ID NOT NULL); | ||
ALTER TABLE ASSOCIATION_BKG_EFO_TRAIT ADD CONSTRAINT ASSC_BKG_EFO_ASSC_ID_FK FOREIGN KEY (ASSOCIATION_ID) REFERENCES ASSOCIATION (ID); | ||
ALTER TABLE ASSOCIATION_BKG_EFO_TRAIT ADD CONSTRAINT ASSC_BKG_EFO_TRAIT_ID_FK FOREIGN KEY (EFO_TRAIT_ID) REFERENCES EFO_TRAIT (ID); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
...ools/goci-solr-indexer/src/main/java/uk/ac/ebi/spot/goci/model/BackgroundEfoDocument.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package uk.ac.ebi.spot.goci.model; | ||
|
||
import org.apache.solr.client.solrj.beans.Field; | ||
|
||
/** | ||
* Javadocs go here! | ||
* | ||
* @author Ala Abid | ||
* @date 26/05/21 | ||
*/ | ||
public class BackgroundEfoDocument extends OntologyEnabledDocument<EfoTrait> { | ||
@Field private String mappedBkgLabel; | ||
@Field private String mappedBkgUri; | ||
|
||
public BackgroundEfoDocument(EfoTrait efoTrait) { | ||
super(efoTrait); | ||
this.mappedBkgLabel = efoTrait.getTrait(); | ||
this.mappedBkgUri = efoTrait.getUri(); | ||
// addTraitUri(mappedBkgUri); | ||
} | ||
|
||
public String getMappedBkgLabel() { | ||
return mappedBkgLabel; | ||
} | ||
|
||
public String getMappedBkgUri() { | ||
return mappedBkgUri; | ||
} | ||
} |
Oops, something went wrong.