Changes between Version 4 and Version 5 of DespoinaLog/2010/12/09
- Timestamp:
- 2010-12-09T12:35:30+01:00 (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DespoinaLog/2010/12/09
v4 v5 6 6 * create new table biobank from pheno project as follows: 7 7 8 mysql> create table biobank_new select Acronym, Category, Type, Size, !LastUpdate , Description, id from biobank ;8 mysql> create table biobank_new select Acronym, Category, Type, Size, !LastUpdate , Description, id from biobank ; 9 9 10 10 (only fields that exist in biobank in gcc project) … … 12 12 * Dump and insert new table in gcc project. 13 13 * $ mysqldump5 -u root -p bbmri_old biobank_new > biobank_new.mysql 14 * Edit 14 * Edit biobank_new.mysql and replace biobank_new (table) with biobank 15 15 * 16 16 * mysql5 -u root -p bbmri < biobank_new.mysql 17 18 == select query retrieving records in molgenis form == 19 === We need data inside INNER JOIN tables === 20 select count(*) as num_rows FROM Biobank INNER JOIN 21 22 Panel ON (Biobank.id = Panel.id) INNER JOIN 23 24 !ObservationTarget ON (Biobank.id = !ObservationTarget.id) INNER JOIN 25 26 !ObservationElement ON (Biobank.id = !ObservationElement.id) LEFT JOIN Investigation AS xref_Investigation ON xref_Investigation.id = !ObservationElement.Investigation LEFT JOIN !OntologyTerm AS xref_ontologyReference ON xref_ontologyReference.id = !ObservationElement.ontologyReference LEFT JOIN !OntologyTerm AS xref_Species ON xref_Species.id = Panel.Species LEFT JOIN !OntologyTerm AS xref_PanelType ON xref_PanelType.id = Panel.!PanelType LEFT JOIN !OntologyTerm AS xref_Category ON xref_Category.id = Biobank.Category WHERE !ObservationElement.!__Type = 'Biobank'