Index: trunk/ippMonitor/raw/columns_in_db.php
===================================================================
--- trunk/ippMonitor/raw/columns_in_db.php	(revision 28668)
+++ trunk/ippMonitor/raw/columns_in_db.php	(revision 28669)
@@ -23,13 +23,96 @@
 // Table names query
 $tableNames = array (
-	    0 => "camRun",
-	    1 => "camProcessedExp",
-	    2 => "chipProcessedImfile",
-	    3 => "chipRun",
-	    4 => "fakeRun",
-	    5 => "rawExp",
-	    6 => "warpRun",
-	    7 => "warpSkyCellMap",
-	    8 => "warpSummary",
+		     "Label", 
+		     "addMask", 
+		     "addProcessedExp", 
+		     "addRun", 
+		     "calDB", 
+		     "calRun", 
+		     "camMask", 
+		     "camProcessedExp", 
+		     "camRun", 
+		     "chipBackgroundImfile", 
+		     "chipBackgroundRun", 
+		     "chipImfile", 
+		     "chipMask", 
+		     "chipProcessedImfile", 
+		     "chipRun", 
+		     "dbversion", 
+		     "detInputExp", 
+		     "detNormalizedExp", 
+		     "detNormalizedImfile", 
+		     "detNormalizedStatImfile", 
+		     "detProcessedExp", 
+		     "detProcessedImfile", 
+		     "detRegisteredImfile", 
+		     "detResidExp", 
+		     "detResidImfile", 
+		     "detRun", 
+		     "detRunSummary", 
+		     "detStackedImfile", 
+		     "diffInputSkyfile", 
+		     "diffPhotRun", 
+		     "diffPhotSkyfile", 
+		     "diffRun", 
+		     "diffSkyfile", 
+		     "diffSummary", 
+		     "distComponent", 
+		     "distRun", 
+		     "distTarget", 
+		     "dqstatsContent", 
+		     "dqstatsRun", 
+		     "fakeMask", 
+		     "fakeProcessedImfile", 
+		     "fakeRun", 
+		     "flatcorrAddstarLink", 
+		     "flatcorrCamLink", 
+		     "flatcorrChipLink", 
+		     "flatcorrRun", 
+		     "magicDSFile", 
+		     "magicDSRun", 
+		     "magicInputSkyfile", 
+		     "magicMask", 
+		     "magicNodeResult", 
+		     "magicRun", 
+		     "magicTree", 
+		     "minidvodbProcessed", 
+		     "minidvodbRun", 
+		     "newExp", 
+		     "newImfile", 
+		     "publishClient", 
+		     "publishDone", 
+		     "publishRun", 
+		     "pzDataStore", 
+		     "pzDownloadExp", 
+		     "pzDownloadImfile", 
+		     "rawExp", 
+		     "rawImfile", 
+		     "rcDSFileset", 
+		     "rcDestination", 
+		     "rcInterest", 
+		     "rcRun", 
+		     "receiveFile", 
+		     "receiveFileset", 
+		     "receiveResult", 
+		     "receiveSource", 
+		     "stackAssociation", 
+		     "stackAssociationMap", 
+		     "stackInputSkyfile", 
+		     "stackRun", 
+		     "stackSumSkyfile", 
+		     "stackSummary", 
+		     "staticskyInput", 
+		     "staticskyResult", 
+		     "staticskyRun", 
+		     "summitExp", 
+		     "summitImfile", 
+		     "warpBackgroundRun", 
+		     "warpBackgroundSkyfile", 
+		     "warpImfile", 
+		     "warpMask", 
+		     "warpRun", 
+		     "warpSkyCellMap", 
+		     "warpSkyfile", 
+		     "warpSummary", 
 		     );
 
@@ -37,35 +120,33 @@
 
 foreach ($tableNames as $tIndex => $tableName) {
-	$sql = "show columns from `$tableName`";
-	$qry = $db->query($sql);
-	if (dberror($qry)) {
-	  echo "<b>error reading querying table</b><br>\n";
-	    echo "<br><small><b> table query : $sql </b></small><br>\n";
-	    menu_end();
-	}
-	if (!$qry->fetchInto($row)) {
-	  echo "<b>error querying table</b><br>\n";
-  	  echo "<br><small><b>query : $sql </b></small><br>\n";
-  	  menu_end();
-	}
-	$count = 0;
-	$line = "";
-	$values = array();
-	while ($qry->fetchInto($row)) {
-	  foreach ($row as $index => $value) {
-	    if ($index == 0) {
-	      $values[] = $value;
-	    }
-	  }
-	}
-	asort($values);
-	foreach ($values as $index => $value) {
-	  #echo "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;".$index." => ".$value."<br>";
-	  $count++;
-	    $line .= "<option value=\"$value\">$value</option>\n";
-	}
-	echo "<b>Table name: $tableName</b><br>\n";
-	echo "Count = $count columns<br>\n";
-	echo "<select name=\"blah\">\n".$line."\n</select><br>\n";
+  $sql = "show columns from $tableName";
+  $qry = $db->query($sql);
+  if (dberror($qry)) {
+    echo "<b>error reading querying table</b><br>\n";
+    echo "<br><small><b> table query : $sql </b></small><br>\n";
+    menu_end();
+  }
+  $count = 0;
+  $line = "";
+  $values = array();
+  while ($qry->fetchInto($row)) {
+    # print "[".$row[0]."]<br>\n";
+    foreach ($row as $index => $value) {
+      if ($index == 0) {
+	$values[] = $value;
+      }
+    }
+  }
+  # print count($values)."<br>\n";
+  asort($values);
+  # print count($values)."<br>\n";
+  foreach ($values as $index => $value) {
+    #echo "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;".$count." => ".$value."<br>";
+    $line .= "<option value=\"$value\">$count => $value</option>\n";
+    $count++;
+  }
+  echo "<b>Table name: $tableName</b><br>\n";
+  echo "Count = $count columns<br>\n";
+  echo "<select name=\"blah\">\n".$line."\n</select><br>\n";
 }
 
