// lista.php // Title: downlink table session_start(); include("ins/connect.inc.php"); include("header-list.html"); ?> if ( !isset($_SESSION["login"]) ) { echo "
"; echo "
";
$totale=0.;
$str_1 ="create temporary table tmp1 select orbit, count(edtt) as ttt from comm_downlink group by orbit";
$query = mysql_query($str_1);
$str_2 ="select a.orbit, a.edtt, a.nome from comm_downlink as a, tmp1 as b where (a.error < 1000 AND (a.ipm LIKE '%3%' OR a.ipm LIKE '%4%') AND "
."a.orbit=b.orbit AND b.ttt>1)";
$query = mysql_query($str_2);
while ($row = mysql_fetch_row($query))
{
$or=$row[0];
$time=$row[1];
$file=$row[2];
$str="select orbit, edtt, nome from comm_downlink where (error < 1000 AND (ipm LIKE '%3%' OR ipm LIKE '%4%') AND orbit=$or)";
$query_ = MyQuery($str);
$t=$time;
while ($row_ = mysql_fetch_row($query_))
{
$time_=$row_[1];
$file_=$row_[2];
if ($file_>$file) {$t=$time_;}
} //echo "or=".$or." newor=".$row_[0]." time=".$t." file=".$file." newfile=".$file_." "; $totale=$totale+$t; } $str_3="create temporary table tmp2 select a.orbit from comm_downlink as a, tmp1 as b where a.orbit=b.orbit AND b.ttt<2"; $query = MyQuery($str_3); $strsql = "select sum(a.edtt) as totalecolonna from comm_downlink as a, tmp2 as c WHERE (a.error < 1000 AND (a.ipm LIKE '%3%' OR a.ipm LIKE '%4%') AND " ."a.orbit=c.orbit)"; $query = mysql_query($strsql); $row = mysql_fetch_array($query); //echo $totale." "; $totale = $totale+$row["totalecolonna"]; //echo $totale." "; //$strsql = "select sum(temp.edtt) as totalecolonna from (select distinct(orbit), edtt from comm_downlink WHERE (error < 1000 AND (ipm LIKE '%3%' OR ipm LIKE '%4%'))) as temp"; //$query = mysql_query($strsql); //$row = mysql_fetch_array($query); //$totale = $row["totalecolonna"]; echo "TOT. Effective data taking time (s) with IPM 3/4: $totale"; echo " |
"; //$strsql = "select sum(edtt) as totalecolonna from comm_downlink WHERE (ipm NOT LIKE '%3%' AND ipm NOT LIKE '%4%')"; MyQuery("create temporary table tmp3 select distinct(orbit), edtt from comm_downlink WHERE (ipm NOT LIKE '%3%' AND ipm NOT LIKE '%4%')"); $strsql = "select sum(edtt) as totalecolonna from tmp3"; $query = mysql_query($strsql); $row = mysql_fetch_array($query); $totale = $row["totalecolonna"]; echo "TOT. Effective data taking time (s) without IPM 3/4: $totale"; echo " |
"; //$strsql = "select sum(edtt) as totalecolonna from comm_downlink "; MyQuery("create temporary table tmp4 select distinct(orbit), edtt from comm_downlink"); $strsql = "select sum(edtt) as totalecolonna from tmp4"; //$strsql = "select sum(temp2.edtt) as totalecolonna from (select distinct(orbit), edtt from comm_downlink) as temp2"; $query = mysql_query($strsql); $row = mysql_fetch_array($query)or die (mysql_error()); $totale = $row["totalecolonna"]; echo "TOT. Effective data taking time (s): $totale"; echo " |
Taking Time (s) |
||||||||||||||
change | "; echo "delete | "; } echo "".$row["id"]." | "; echo "".$row["nome"]." | "; echo "".$row["orbit"]." | "; echo "".$row["time"]." | "; echo "".$row["edtt"]." | "; $myData = Explode( "-", $row["datedld"] ); echo "$myData[2]/$myData[1]/$myData[0] - ".$row["oradld"]." | "; $myData1 = Explode( "-", $row["datedlk"] ); echo "$myData1[2]/$myData1[1]/$myData1[0] - ".$row["oradlk"]." | "; echo "".$row["rr"]." | "; echo "".$row["error"]." | "; echo "".$row["a18"]." | "; echo "".$row["ipm"]." | "; echo "".$row["ws"]." | "; echo "".$row["comments"]." | "; echo "