b63c6cd3032d2395c889cb0a58b28464d9d7f6a6
braney
  Tue Mar 17 09:01:34 2020 -0700
fix some of the problems from #25160

diff --git src/hg/near/hgNear/association.c src/hg/near/hgNear/association.c
index 14ab6fa..9cd96f3 100644
--- src/hg/near/hgNear/association.c
+++ src/hg/near/hgNear/association.c
@@ -482,31 +482,31 @@
 
 
 /* Build up hash full of all go IDs associated with gene. */
 if (geneId != NULL)
     {
     sqlSafef(query, sizeof(query), ord->queryOne, geneId);
     sr = sqlGetResult(conn, query);
     while ((row = sqlNextRow(sr)) != NULL)
 	{
 	hashAdd(curTerms, row[0], NULL);
 	}
     sqlFreeResult(&sr);
     }
 
 /* Stream through association table counting matches. */
-sqlSafef(query, sizeof(query), "%-s", ord->queryOne);  // purely for side-effect of adding NOSQLINJ prefix
+sqlSafef(query, sizeof(query), "%-s", ord->queryAll);  // purely for side-effect of adding NOSQLINJ prefix
 sr = sqlGetResult(conn, query);
 while ((row = sqlNextRow(sr)) != NULL)
     {
     if (hashLookup(curTerms, row[1]))
 	{
 	struct hashEl *hel = hashLookup(lookupHash, row[0]);
 	while (hel != NULL)
 	    {
 	    gp = hel->val;
 	    gp->count += 1;
 	    hel = hashLookupNext(hel);
 	    }
 	}
     }
 sqlFreeResult(&sr);