Is it possible to get around mysql_unbuffered_query()'s limitation of having one query running at a time by opening a second connection?
For example, the following code is giving me the error:
mysql_select_db(): Function called without first fetching all rows from a previous unbuffered query
$feedData = mysql_unbuffered_query($sql, $this->_unbufferedDbManager->db->connection);
while ($record = mysql_fetch_assoc($feedData)) {
File::fputcsv($this->_fileHandle, $record, $this->delimiter, $this->enclosure);
$sql = "UPDATE transactions
SET feed_transmit_date = '$this->today'
WHERE transaction_id = " . $record['transaction_id'];
$this->dbManager->DbQuery($sql);
print_r($this->_unbufferedDbManager->db->connection);
print_r($this->dbManager->db->connection);
}
The two print_r()'s at the end output: Resource id #637Resource id #639
DbManager is an old pear data access layer
Note: I would have used a mysql_unbuffered_query tag, but I recently opened a bounty that put me below the "create new tags privilege."