aboutsummaryrefslogtreecommitdiff
path: root/wqflask/maintenance
diff options
context:
space:
mode:
authorroot2014-02-20 15:33:07 -0600
committerroot2014-02-20 15:33:07 -0600
commit7022613e93a00a111b8548e41922c12315944f8e (patch)
treedc98a689af6cb251602485dae807607af0feb4c5 /wqflask/maintenance
parent153ec8f16c3d9ef936e244c568751788d1413a62 (diff)
downloadgenenetwork2-7022613e93a00a111b8548e41922c12315944f8e.tar.gz
Committer: root <root@alexandria.uthsc.edu>
On branch master
Diffstat (limited to 'wqflask/maintenance')
-rw-r--r--wqflask/maintenance/dataset/load_phenotypes.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/wqflask/maintenance/dataset/load_phenotypes.py b/wqflask/maintenance/dataset/load_phenotypes.py
index 44876d53..36c14990 100644
--- a/wqflask/maintenance/dataset/load_phenotypes.py
+++ b/wqflask/maintenance/dataset/load_phenotypes.py
@@ -144,6 +144,23 @@ def main(argv):
NStrain.`count`=%s
"""
cursor.execute(sql, (dataid, strainid, n))
+ # PublishXRef
+ sql = """
+ INSERT INTO PublishXRef
+ SET
+ PublishXRef.`InbredSetId`=%s,
+ PublishXRef.`PhenotypeId`=%s,
+ PublishXRef.`PublicationId`=%s,
+ PublishXRef.`DataId`=%s
+ """
+ cursor.execute(sql, (inbredsetid, phenotypeid, publicationid, dataid))
+ rowcount = cursor.rowcount
+ publishxrefid = con.insert_id()
+ print "INSERT INTO PublishXRef: %d record: %d" % (rowcount, publishxrefid)
+ # for loop next
+ dataid += 1
+ # release
+ con.close()
if __name__ == "__main__":
print "command line arguments:\n\t%s" % sys.argv