FIX Reset query generator after iteration is complete (#139)
This commit is contained in:
parent
c529b8375c
commit
15d4e9550b
|
@ -62,6 +62,8 @@ class PostgreSQLQuery extends Query
|
|||
while ($row = pg_fetch_array($this->handle, null, PGSQL_NUM)) {
|
||||
yield $this->parseResult($row);
|
||||
}
|
||||
// Reset so the query can be iterated over again
|
||||
pg_result_seek($this->handle, 0);
|
||||
}
|
||||
|
||||
public function numRecords()
|
||||
|
|
Loading…
Reference in New Issue