9163bbc2e39ec26d12c8a90bb26e365792f60670
ceisenhart
  Sun Jan 11 17:15:33 2015 -0800
Added a 'data last updated' tag to table display after 'Row Count' and before 'Format description'
diff --git src/hg/hgTables/schema.c src/hg/hgTables/schema.c
index 7d4a03a..d29797a 100644
--- src/hg/hgTables/schema.c
+++ src/hg/hgTables/schema.c
@@ -18,31 +18,30 @@
 #include "trackDb.h"
 #include "joiner.h"
 #include "tableDescriptions.h"
 #include "asParse.h"
 #include "customTrack.h"
 #include "bedCart.h"
 #include "hgMaf.h"
 #include "hgTables.h"
 #include "wikiTrack.h"
 #include "makeItemsItem.h"
 #include "bedDetail.h"
 #include "pgSnp.h"
 #include "hubConnect.h"
 #include "errCatch.h"
 
-
 static char *nbForNothing(char *val)
 /* substitute   for empty strings to keep table formating sane */
 {
 char *s = skipLeadingSpaces(val);
 if ((s == NULL) || (s[0] == '\0'))
     return " ";
 else
     return val;
 }
 
 static char *abbreviateInPlace(char *val, int len)
 /* Abbreviate a string to len characters.  */
 {
 int vlen = strlen(val);
 if (vlen > len)
@@ -371,31 +370,33 @@
 if (tdbForConn == NULL)
     conn = hAllocConn(db);
 else
     conn = hAllocConnTrack(db, tdbForConn);
 struct joiner *joiner = allJoiner;
 struct joinerPair *jpList, *jp;
 struct asObject *asObj = asForTable(conn, table);
 char *splitTable = chromTable(conn, table);
 
 hPrintf("<B>Database:</B> %s", db);
 hPrintf("&nbsp;&nbsp;&nbsp;&nbsp;<B>Primary Table:</B> %s", table);
 if (!sameString(splitTable, table))
     hPrintf(" (%s)", splitTable);
 hPrintf("&nbsp;&nbsp;&nbsp;&nbsp;<B>Row Count: </B>  ");
 printLongWithCommas(stdout, sqlTableSize(conn, splitTable));
-hPrintf("<BR>\n");
+char *date = firstWordInLine(sqlTableUpdate(conn, table));
+if (date != NULL)
+    printf("&nbsp&nbsp<B> Data last updated:&nbsp;</B>%s<BR>\n", date);
 if (asObj != NULL)
     hPrintf("<B>Format description:</B> %s<BR>", asObj->comment);
 describeFields(db, splitTable, asObj, conn);
 if (tdbForConn != NULL)
     {
     char *type = tdbForConn->type;
     if (startsWithWord("bigWig", type))
 	printf("<BR>This table simply points to a file in "
 	       "<A HREF=\"/goldenPath/help/bigWig.html\" TARGET=_BLANK>"
 	       "BigWig</A> format.<BR>\n");
     }
 jpList = joinerRelate(joiner, db, table);
 
 /* sort and unique list */
 slUniqify(&jpList, joinerPairCmpOnAandB, joinerPairFree);