From 94dd9844fb55f4576d3a079e9d5e59ebbf911b8c Mon Sep 17 00:00:00 2001 From: Zachary Sloan Date: Tue, 27 Nov 2012 17:59:17 -0600 Subject: Created subclass for each main data set type and moved the code for getting trait info that was in search_results.py into its respective class Renamed webqtlDataset to DataSet/create_dataset in webqtlTrait.py, webqtlDatabaseFunction.py, and CorrelationPage.py Got search page running again for mRNA assay data sets with these changes --- wqflask/dbFunction/webqtlDatabaseFunction.py | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) (limited to 'wqflask/dbFunction') diff --git a/wqflask/dbFunction/webqtlDatabaseFunction.py b/wqflask/dbFunction/webqtlDatabaseFunction.py index 7e33da3f..8f923b8a 100755 --- a/wqflask/dbFunction/webqtlDatabaseFunction.py +++ b/wqflask/dbFunction/webqtlDatabaseFunction.py @@ -19,14 +19,7 @@ # # # This module is used by GeneNetwork project (www.genenetwork.org) -# -# Created by GeneNetwork Core Team 2010/08/10 -# -# Last updated by Xiaodong Zhou 2011/Jan/20 -#webqtlDatabaseFunction.py -# -#This file consists of various database related functions; the names are generally self-explanatory. import MySQLdb import string @@ -206,21 +199,21 @@ def getTissueCountByTissueProbeSetFreezeId(cursor=None, TissueProbeSetFreezeId=N ########################################################################### # input: cursor, TissueProbeSetFreezeId (int) -# output: DatasetName(string),DatasetFullName(string) -# function: retrieve DatasetName, DatasetFullName based on TissueProbeSetFreezeId +# output: DataSetName(string),DataSetFullName(string) +# function: retrieve DataSetName, DataSetFullName based on TissueProbeSetFreezeId ########################################################################### -def getDatasetNamesByTissueProbeSetFreezeId(cursor=None, TissueProbeSetFreezeId=None): +def getDataSetNamesByTissueProbeSetFreezeId(cursor=None, TissueProbeSetFreezeId=None): query ="select Name, FullName from TissueProbeSetFreeze where Id=%s" % TissueProbeSetFreezeId try: cursor.execute(query) result = cursor.fetchone() - DatasetName = result[0] - DatasetFullName =result[1] + DataSetName = result[0] + DataSetFullName =result[1] except: - DatasetName =None - DatasetFullName =None + DataSetName =None + DataSetFullName =None - return DatasetName, DatasetFullName + return DataSetName, DataSetFullName ########################################################################### # input: cursor, geneIdLst (list) -- cgit v1.2.3