四十三章 PHP 製作資料透視表

wangsys發表於2021-09-09

echo "";
$sql3= "SELECT FROM cs GROUP BY date";
$ret3 = mysql_query($sql3, $link);
while ($row3 = mysql_fetch_assoc($ret3)) {
echo "";
}
echo "
";
$sql= "SELECT
FROM cs GROUP BY name";
$ret = mysql_query($sql, $link);
while ($row = mysql_fetch_assoc($ret)) {
echo "";
$sql2= "SELECT FROM cs GROUP BY date";
$ret2 = mysql_query($sql2, $link);
while ($row2 = mysql_fetch_assoc($ret2)) {
$sql4= "SELECT
FROM cs where date='".$row2['date']."'and name='".$row['name']."'";
$ret4 = mysql_query($sql4, $link);
$row4 = mysql_fetch_assoc($ret4) ;
echo "";
}
echo "
";
}
圖片描述

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/3244/viewspace-2799759/,如需轉載,請註明出處,否則將追究法律責任。

相關文章