$runVar['counts']['now']['collections_table'] += getTableRowCount($psTableRowCount, $tbl); $added = $pdo->queryOneRow(sprintf('SELECT %s AS dateadded FROM %s', $stamp, $tbl)); if (isset($added['dateadded']) && is_numeric($added['dateadded']) && $added['dateadded'] < $age) { $age = $added['dateadded']; } break; case strpos($tbl, 'binaries_') !== false: $runVar['counts']['now']['binaries_table'] += getTableRowCount($psTableRowCount, $tbl); break; // This case must come before the 'parts_' one. // This case must come before the 'parts_' one. case strpos($tbl, 'missed_parts_') !== false: $runVar['counts']['now']['missed_parts_table'] += getTableRowCount($psTableRowCount, $tbl); break; case strpos($tbl, 'parts_') !== false: $runVar['counts']['now']['parts_table'] += getTableRowCount($psTableRowCount, $tbl); break; default: } } $runVar['timers']['newOld']['oldestcollection'] = $age; //free up memory used by now stale data unset($age, $added, $tables); $runVar['timers']['query']['tpg_time'] = time() - $timer07; $runVar['timers']['query']['tpg1_time'] = time() - $timer01; } } } $runVar['timers']['timer2'] = time(); //assign postprocess values from $proc if (is_array($proc1res)) {
return $row_cnt; } // List all tables under current database echo "<h2> Database Tables Display</h2>"; $dbname = $_SESSION['dbname']; $sql = "SHOW TABLES FROM {$dbname};"; $result = mysqli_query($conn, $sql); if (!$result) { echo "DB Error, could not list tables\n"; echo 'MySQL Error: ' . mysql_error(); exit; } $_tRowCount = 1; //...Print out all the tables while ($row = mysqli_fetch_array($result)) { $_qRowCount = getTableRowCount($row[0], $conn); echo "<tr><td>{$_tRowCount}</td><td> {$row[0]} </td><td> {$_qRowCount} </td> </tr>\n"; $_tRowCount = $_tRowCount + 1; } mysqli_free_result($result); ?> </table> <div id= "DBControlPannel" > <h1> Database Control Panel </h1> <h3> Current Database: </h3> <h3> Delete Database </h3> <h3> Create Database </h3> </div> </form> </div> </div>