diff ensure_synced.py @ 6:68ca17b451f2 draft

Uploaded
author greg
date Fri, 17 Dec 2021 17:46:31 +0000
parents 81232205b179
children 59edc91d0bea
line wrap: on
line diff
--- a/ensure_synced.py	Wed Nov 11 18:16:52 2020 +0000
+++ b/ensure_synced.py	Fri Dec 17 17:46:31 2021 +0000
@@ -35,7 +35,7 @@
         self.conn = psycopg2.connect(**args)
 
     def get_affy_ids_from_db(self):
-        cmd = "SELECT affy_id FROM sample WHERE genotype_id NOT IN (SELECT id FROM genotype WHERE coral_mlg_clonal_id = 'failed') ORDER BY affy_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()