運行結果集時,與其他方法相比,此方法的效率如何?通過結果集運行時的效率
for ($iCont=0; $iCont < mysql_num_rows($this->rsQuery); $iCont++)
{
mysql_data_seek($this->rsQuery,$iCont);
$row=mysql_fetch_assoc($this->rsQuery);
//more things here like write row or push it to a global array
}
使用mysql_data_seek是否存在任何效率問題,即使它是按照有序序列完成的?
mysql_num_rows()在開始時如何?確實影響?
那麼,有沒有更好的方法?
我想要實現的是返回一個關聯數組和所有結果集內容的方法,另一個方法是用數據創建一個網格(html表格)。
謝謝