<html><link rel="SHORTCUT ICON" href="favicon.ico">
<body background='textblue.jpg'>
<head><title> Atenae - Catalog Explorer for DB2</title></head>

<div align="left"><img src="at3.gif" width="60" height="60" onclick=window.open('ajdb.html','ajuda','width=300,height=200,scrollbars=yes')></div>
<div align="center"><a href='principal.html'> Principal  </a>
&nbsp&nbsp
<a href='lista_db.php' target=fse> DBs  </a>
&nbsp&nbsp
<a href='stmtr3.php?sql=select *                                                       from sysibm.sysdummy1&q=10&dbasef=DSNDB06&dban=DSNDB06&tban=SYSDUMMY1&tabela=SYSDUMMY1&criador=SYSIBM&cran=SYSIBM'> Query  </a>
&nbsp&nbsp
</div>


<?php

include 'liga.php';


if ($dbconn != 0) {

include 's1db.php';
include 's2db.php';
include 's0db.php';


   $result = odbc_exec($dbconn, $stmt) ;

   if ($result == 0) {
      $sqlerror = odbc_errormsg($dbconn);
      echo $sqlerror ; }

   else {

      echo "<table width='40%' border='0' align='center'>
           <caption>
           <H1>Databases</H1><BR>
           </caption>
           <tr> <th onclick=alert('nome_do_database') bgcolor='#FFFF9F' align='center' scope='col'> Database </th>
                <th onclick=alert('quantidade_de_tabelas_no_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. tabelas </th>
                <th onclick=alert('quantidade_de_views_no_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. views </th>
                <th onclick=alert('quantidade_de_planos_referenciando_o_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. plano </th>
                <th onclick=alert('quantidade_de_packages_referenciando_o_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. packages </th>
                <th onclick=alert('quantidade_de_tablespaces_no_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. tablespaces </th>
                <th onclick=alert('nmero_de_sequncia_na_pgina') bgcolor='#FFFF9F' align='center' scope='col'> seq </th>
           </tr>" ;

      $n=1;

      while ($row = odbc_fetch_array($result)) {
        echo "<tr onmouseover=style.backgroundColor='#e7e7e7' onmouseout=style.backgroundColor=''>";
        echo "<th align='left' scope='col'><a href='alerta.php?db=";
        echo urlencode($row['DBNAME']);
        echo "&dias=7&qix=3' target=fi> $row[DBNAME] </th>";
        echo "<th align='center' scope='col'><a href='lista_tb_22.php?db=";
        echo urlencode($row['DBNAME']);
        echo "&tp=T&ts=%&or=2,3 asc ' target=fi> $row[QTDT] </a></th>";
        echo "<th align='center' scope='col'><a href='lista_vi_21.php?db=";
        echo urlencode($row['DBNAME']);
        echo "&tp=V&or=1,2 asc ' target=fi> $row[QTDV] </a></th>
              <th align='center' scope='col'><a href='lista_plandep_db2i.php?db=";
        echo urlencode($row['DBNAME']);
        echo "' target=fi> $row[QTDP] </a></th>
              <th align='center' scope='col'><a href='lista_packdep_db2i.php?db=";
        echo urlencode($row['DBNAME']);
        echo "' target=fi> $row[QTDK] </a></th>
              <th align='center' scope='col'><a href='lista_ts_2i.php?db=";
        echo urlencode($row['DBNAME']);
        echo "&ts=%&sg=%' target=fi> $row[QTDS] </a></th>
              <th bgcolor='#FFFF9F' align='center' scope='col'> $n </th>
              </tr>";
        $n++;

      if (ceil($n / 10) == ($n / 10))

       echo"<tr> <th onclick=alert('nome_do_database') bgcolor='#FFFF9F' align='center' scope='col'> Database </th>
                <th onclick=alert('quantidade_de_tabelas_no_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. tabelas </th>
                <th onclick=alert('quantidade_de_views_no_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. views </th>
                <th onclick=alert('quantidade_de_planos_referenciando_o_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. plano </th>
                <th onclick=alert('quantidade_de_packages_referenciando_o_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. packages </th>
                <th onclick=alert('quantidade_de_tablespaces_no_database') bgcolor='#FFFF9F' align='center' scope='col'> qtd. tablespaces </th>
                <th onclick=alert('nmero_de_sequncia_na_pgina') bgcolor='#FFFF9F' align='center' scope='col'> seq </th>
            </tr>" ;

      }

     echo "</table> </body> </html>" ;

   }
}

odbc_close($dbconn);

?>

