208a148e1625db67b80fa3e38a21aba532394810
braney
  Tue Dec 5 11:59:25 2023 -0800
ignore overrides when looking for parents

diff --git src/hg/utils/tdbQuery/tdbQuery.c src/hg/utils/tdbQuery/tdbQuery.c
index 98f8c16..f878cd5 100644
--- src/hg/utils/tdbQuery/tdbQuery.c
+++ src/hg/utils/tdbQuery/tdbQuery.c
@@ -559,30 +559,32 @@
 if (!sameString(parentFp->fileName, childFp->fileName))
     return BIGNUM/2;
 int distance = childFp->startLineIx - parentFp->startLineIx;
 if (distance < 0)
     return BIGNUM/4 - distance;
 return distance;
 }
 
 static struct tdbRecord *findParent(struct tdbRecord *rec,
                                     char *parentFieldName, struct hash *hash,
                                     unsigned currentReleaseBit)
 /* Find parent record if possible.  This is a bit complicated by wanting to
  * match parents and children from the same release if possible.  Our
  * strategy is to just ignore records from the wrong release. */
 {
+if (rec->override)  // don't do these
+    return NULL;
 if (clNoCompSub)
     return NULL;
 struct tdbField *parentField = tdbRecordField(rec, parentFieldName);
 if (parentField == NULL)
     return NULL;
 char *parentLine = parentField->val;
 int len = strlen(parentLine);
 char buf[len+1];
 strcpy(buf, parentLine);
 char *parentName = firstWordInLine(buf);
 struct hashEl *hel;
 struct tdbRecord *closestParent = NULL;
 int closestDistance = BIGNUM;
 for (hel = hashLookup(hash, parentName); hel != NULL; hel = hashLookupNext(hel))
     {