Skip to content

Commit

Permalink
Don't load all rows into memory.
Browse files Browse the repository at this point in the history
  • Loading branch information
yunosh committed Sep 19, 2016
1 parent 83e9fd5 commit 9c1d5f2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions migration/3_imp_maillog_update.php
Expand Up @@ -23,7 +23,7 @@ public function up()
if (in_array('horde_histories', $tableList)) {
$sql = sprintf('SELECT history_id, object_uid FROM horde_histories WHERE object_uid LIKE %s', $this->quote('imp.%'));
$this->announce('Loading existing history from the maillog.');
$rows = $this->_connection->selectAll($sql);
$rows = $this->_connection->select($sql);
$sql = 'UPDATE horde_histories SET object_uid = ? WHERE history_id = ?';
$this->announce('Updating entries. This may take some time.');
foreach ($rows as $row) {
Expand All @@ -42,7 +42,7 @@ public function down()
if (in_array('horde_histories', $tableList)) {
$sql = sprintf('SELECT history_id, object_uid FROM horde_histories WHERE object_uid LIKE %s', $this->quote('imp:%'));
$this->announce('Loading existing history from the maillog.');
$rows = $this->_connection->selectAll($sql);
$rows = $this->_connection->select($sql);
$sql = 'UPDATE horde_histories SET object_uid = ? WHERE history_id = ?';
$this->announce('Updating entries. This may take some time.');
foreach ($rows as $row) {
Expand Down

0 comments on commit 9c1d5f2

Please sign in to comment.