Heim > Fragen und Antworten > Hauptteil
$result = mysql_query("select * from brand order by yesterday_str");
while($row = mysql_fetch_array($result))
{
echo "'".$row['yesterday_str']."'";
echo ",";
}
现在我通过上面的方法能把brand表里面的所有字段数据都提取出来
brand表里面有a,b,c,d,e,f,g这7个字段,
我怎么修改才能只提取abcfg这5个字段的数据呢?
ringa_lee2017-05-16 13:12:22
$result = mysql_query("select a,b,c,f,g from brand order by yesterday_str");
while($row = mysql_fetch_array($result))
{
echo "'".$row['yesterday_str']."'";
echo ",";
}
//这样就好了吧????