📜  将查询结果转换为数组 php 代码示例

📅  最后修改于: 2022-03-11 14:54:14.001000             🧑  作者: Mango

代码示例1
$result = "select * from random_table where id = 1";

$rows = [];
while($row = mysqli_fetch_array($result))
{
    $rows[] = $row;
}