Mercurial > repos > greg > ensure_synced
changeset 7:59edc91d0bea draft
Uploaded
author | greg |
---|---|
date | Fri, 17 Dec 2021 17:55:08 +0000 |
parents | 68ca17b451f2 |
children | aaa6ae7c64de |
files | ensure_synced.py |
diffstat | 1 files changed, 2 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/ensure_synced.py Fri Dec 17 17:46:31 2021 +0000 +++ b/ensure_synced.py Fri Dec 17 17:55:08 2021 +0000 @@ -5,9 +5,8 @@ import sys import psycopg2 - +from sqlalchemy import create_engine from sqlalchemy import MetaData -from sqlalchemy import create_engine from sqlalchemy.engine.url import make_url metadata = MetaData() @@ -35,7 +34,7 @@ self.conn = psycopg2.connect(**args) def get_affy_ids_from_db(self): - cmd = "SELECT coral_mlg_rep_sample_id, coral_mlg_clonal_id FROM genotype WHERE coral_mlg_rep_sample_id IS NOT NULL AND coral_mlg_rep_sample_id != '' AND coral_mlg_clonal_id != 'failed' ORDER BY coral_mlg_rep_sample_id;” + cmd = "SELECT coral_mlg_rep_sample_id, coral_mlg_clonal_id FROM genotype WHERE coral_mlg_rep_sample_id IS NOT NULL AND coral_mlg_rep_sample_id != '' AND coral_mlg_clonal_id != 'failed' ORDER BY coral_mlg_rep_sample_id;" cur = self.conn.cursor() cur.execute(cmd) rows = cur.fetchall()