== Inconsistency with biobank table (pheno & gcc project) == == problem: == The bbmri.xml describes the table as follows :[[BR]][[BR]] Describes one biobank cohort[[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]] [[BR]][[BR]]Similarly the BBMRIupdateDatabase tries to create these fields. But[[BR]]the created table in DB is missing the fields:[[BR]][[BR]]Institutes (mref), Publications(mref), Contacts (mref), Topics[[BR]](mref), Materials (mref).[[BR]][[BR]]Is this how was supposed to work? Because it causes a problem in mysql[[BR]]input from the previous scheme (in pheno). == == == Approach 1)Solution == * create new table biobank from pheno project as follows: mysql> create table biobank_new select Acronym, Category, Type, Size, !LastUpdate , Description, id from biobank ; (only fields that exist in biobank in gcc project) * Dump and insert new table in gcc project. * $ mysqldump5 -u root -p bbmri_old biobank_new > biobank_new.mysql * Edit biobank_new.mysql and replace biobank_new (table) with biobank * * mysql5 -u root -p bbmri < biobank_new.mysql == == == Approach 2)select query retrieving records in molgenis form == === We need data inside INNER/LEFT JOIN tables === select count(*) as num_rows FROM Biobank INNER JOIN '''Panel''' ON (Biobank.id = Panel.id) INNER JOIN '''!ObservationTarget''' ON (Biobank.id = !ObservationTarget.id) INNER JOIN '''!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' == Approach 3) Fix the xls data file according to the consistencies between these entities. == xls colums :  {{{ Name Type Acronym category_term topics_term institutes_name contacts_lastName size materials_term GWA data n = GWA platform GWA comments description }}}