9553523d22026cfdcf132d7d341969d47b18e182
hartera
  Wed Sep 17 16:08:47 2014 -0700
In getAlignments function, added code for the Retrposed Genes track that gets only the qName equal to an id not like an id for the table query. Otherwise multiple results are returned rather than the single result required for this track details page.
diff --git src/hg/hgc/hgc.c src/hg/hgc/hgc.c
index 55c77a0..19cc64b 100644
--- src/hg/hgc/hgc.c
+++ src/hg/hgc/hgc.c
@@ -5733,30 +5733,35 @@
 	}
     }
 }
 
 struct psl *getAlignments(struct sqlConnection *conn, char *table, char *acc)
 /* get the list of alignments for the specified acc */
 {
 struct sqlResult *sr = NULL;
 char **row;
 struct psl *psl, *pslList = NULL;
 boolean hasBin;
 char splitTable[64];
 char query[256];
 if (!hFindSplitTable(database, seqName, table, splitTable, &hasBin))
     errAbort("can't find table %s or %s_%s", table, seqName, table);
+if (startsWith("ucscRetro", table))
+    {
+    sqlSafef(query, sizeof(query), "select * from %s where qName = '%s'", splitTable, acc);
+    }
+else
     sqlSafef(query, sizeof(query), "select * from %s where qName like '%s%%'", splitTable, acc);
 sr = sqlGetResult(conn, query);
 while ((row = sqlNextRow(sr)) != NULL)
     {
     psl = pslLoad(row+hasBin);
     slAddHead(&pslList, psl);
     }
 sqlFreeResult(&sr);
 slReverse(&pslList);
 return pslList;
 }
 
 struct psl *loadPslRangeT(char *table, char *qName, char *tName, int tStart, int tEnd)
 /* Load a list of psls given qName tName tStart tEnd */
 {