From 0fcadee805a6d4a2007e57a69ab130eb9b1c1a3c Mon Sep 17 00:00:00 2001 From: Zachary Sloan Date: Thu, 18 Jul 2013 17:39:10 -0500 Subject: Added Amelie's rat data genotypes Got human mapping mostly working Fixed dataset dropdown menus --- wqflask/maintenance/gen_select_dataset.py | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'wqflask/maintenance') diff --git a/wqflask/maintenance/gen_select_dataset.py b/wqflask/maintenance/gen_select_dataset.py index d653fd2d..8cb94f20 100644 --- a/wqflask/maintenance/gen_select_dataset.py +++ b/wqflask/maintenance/gen_select_dataset.py @@ -47,6 +47,15 @@ import urlparse from pprint import pformat as pf +#Engine = sa.create_engine(our_settings.SQLALCHEMY_DATABASE_URI) + +# build MySql database connection + +#conn = Engine.connect() + + + + def parse_db_uri(db_uri): """Converts a database URI to the db name, host name, user name, and password""" @@ -106,7 +115,7 @@ def build_types(species, group): (all types except phenotype/genotype are tissues) """ - Cursor.execute("""select distinct Tissue.Name, concat(Tissue.Name, ' mRNA') + Cursor.execute("""select distinct Tissue.Name, Tissue.Name from ProbeFreeze, ProbeSetFreeze, InbredSet, Tissue, Species where Species.Name = %s and Species.Id = InbredSet.SpeciesId and InbredSet.Name = %s and @@ -161,13 +170,9 @@ def build_datasets(species, group, type_name): def main(): """Generates and outputs (as json file) the data for the main dropdown menus on the home page""" -<<<<<<< HEAD parse_db_uri(our_settings.DB_URI) -======= - ->>>>>>> 1a3a456eb7635337a966913f2e2e75c8a89bb92e species = get_species() groups = get_groups(species) types = get_types(groups) -- cgit v1.2.3