src/hg/lib/hdb.c 1.415

1.415 2009/09/28 19:00:34 kent
Patching things to look for all_mrna when chr1_mrna doesn't exist and the like.
Index: src/hg/lib/hdb.c
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/hg/lib/hdb.c,v
retrieving revision 1.414
retrieving revision 1.415
diff -b -B -U 4 -r1.414 -r1.415
--- src/hg/lib/hdb.c	2 Sep 2009 21:59:10 -0000	1.414
+++ src/hg/lib/hdb.c	28 Sep 2009 19:00:34 -0000	1.415
@@ -2904,10 +2904,20 @@
     if (!isSplit)
         {
 	safef(fullName, sizeof(fullName), "%s", rootName);
 	if (!hTableExists(db, fullName))
+	    {
+	    if (sameString(rootName, "mrna") || sameString(rootName, "est"))
+	        {
+		safef(fullName, sizeof(fullName), "all_%s", rootName);
+		rootName = fullName;
+		if (!hTableExists(db, rootName))
+		    return NULL;
+		}
+	    else
 	    return NULL;
 	}
+	}
     AllocVar(hti);
     hashAddSaveName(hash, rootName, hti, &hti->rootName);
     hti->isSplit = isSplit;
     hti->isPos = hFindBed12FieldsAndBinWithConn(conn, fullName,