d983323cd2570af1cf3971763d14ef2d88c06fe4
jcasper
  Wed Feb 19 17:00:19 2025 -0800
sqlTableSize needs to support tables with more than 2B rows (rarely, but it does), refs #35262

diff --git src/hg/test/otest/test1.c src/hg/test/otest/test1.c
index db64458ea0a..0371150c58d 100644
--- src/hg/test/otest/test1.c
+++ src/hg/test/otest/test1.c
@@ -206,31 +206,31 @@
     ++lineCount;
     }
 sqlDisconnect(&conn);
 }
 
 void usage()
 {
 errAbort("usage: test file\n");
 }
 
 char **loadWords()
 /* Load words from table into array. */
 {
 struct sqlConnection *conn = sqlConnect(database);
 struct sqlResult *sr;
-int wordCount;
+long wordCount;
 char **words = NULL;
 int i = 0;
 char **row;
 
 wordCount = sqlTableSize(conn, "word");
 uglyf("Got %d words\n", wordCount);
 words = needMem(wordCount * sizeof(words[0]));
 char query[1024];
 sqlSafef(query, sizeof query, "select * from word");
 sr = sqlQuery(conn, query);
 while ((row = sqlNextRow(sr)) != NULL)
     {
     words[i] = cloneString(row[1]);
     ++i;
     }
@@ -287,31 +287,31 @@
     }
 end = clock1000();
 printf("Time to comma reconstruct file: %4.3f\n", 0.001*(end-start));
 sqlDisconnect(&conn);
 }
 
 void relationRecon(char *fileName)
 /* Do relationship based reconstruction. */
 {
 char **words;
 long start, end;
 struct sqlConnection *conn = sqlConnect(database);
 struct sqlResult *sr;
 char **row;
 FILE *f = mustOpen(fileName, "w");
-int lineCount;
+long lineCount;
 int i;
 char query[256];
 
 start = clock1000();
 words = loadWords();
 end = clock1000();
 printf("Time to load words: %4.3f\n", 0.001*(end-start));
 start = clock1000();
 
 lineCount = sqlTableSize(conn, "lineSize");
 for (i=0; i<lineCount; ++i)
     {
     sqlSafef(query, sizeof query, "select * from lineWords where line = %d", i);
     sr = sqlQuery(conn, query);
     while ((row = sqlNextRow(sr)) != NULL)