mysql_data_seek(result_id, row_number)
This function moves the internal result pointer of the result set identified by result_id to row number row_number, so that the next call to a mysql_fetch_* function will retrieve the specified row. It returns true on success, and false on failure. The first row in a result set is number 0.