Differential D19784 Diff 47290 src/applications/search/management/PhabricatorSearchManagementNgramsWorkflow.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/search/management/PhabricatorSearchManagementNgramsWorkflow.php
Show First 20 Lines • Show All 117 Lines • ▼ Show 20 Lines | foreach ($all_objects as $object) { | ||||
'(%s, 1)', | '(%s, 1)', | ||||
$ngram['ngram']); | $ngram['ngram']); | ||||
} | } | ||||
foreach (PhabricatorLiskDAO::chunkSQL($sql) as $chunk) { | foreach (PhabricatorLiskDAO::chunkSQL($sql) as $chunk) { | ||||
queryfx( | queryfx( | ||||
$conn, | $conn, | ||||
'INSERT IGNORE INTO %T (ngram, needsCollection) | 'INSERT IGNORE INTO %T (ngram, needsCollection) | ||||
VALUES %Q', | VALUES %LQ', | ||||
$engine->getCommonNgramsTableName(), | $engine->getCommonNgramsTableName(), | ||||
$chunk); | $chunk); | ||||
} | } | ||||
echo tsprintf( | echo tsprintf( | ||||
"%s\n", | "%s\n", | ||||
pht( | pht( | ||||
'Updated common ngrams for "%s".', | 'Updated common ngrams for "%s".', | ||||
$display_name)); | $display_name)); | ||||
} | } | ||||
} | } | ||||
} | } |