mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-14 10:52:41 +01:00
879431fb50
Summary: This has to table scan a ginormous table right now, give it a fighting chance with a more usable key. Test Plan: - Launched GC daemon, no errors. - Used test console to create a new transcript. - Viewed some old transcripts. - Ran EXPLAIN on the SELECT and verified it was utilizing the garbageCollected key. Reviewed By: jungejason Reviewers: jungejason, tuomaspelkonen, aran CC: aran, epriestley, jungejason Differential Revision: 735
9 lines
286 B
SQL
9 lines
286 B
SQL
ALTER TABLE phabricator_herald.herald_transcript
|
|
ADD garbageCollected BOOL NOT NULL DEFAULT 0;
|
|
|
|
UPDATE phabricator_herald.herald_transcript
|
|
SET garbageCollected = 1
|
|
WHERE objectTranscript = "";
|
|
|
|
ALTER TABLE phabricator_herald.herald_transcript
|
|
ADD KEY (garbageCollected, time);
|