Files
omnivore/packages/db/migrations/0074.undo.migrate_elastic_page_id_data.sql
Jackson Harper 56c45fd1f6 Postgres migrations for the Elastic backend migration
These are cherry picked from the elastic branch so we can run them
and migrate data before moving to elastic as the primary page
backend.
2022-03-15 14:00:22 -07:00

13 lines
376 B
PL/PgSQL
Executable File

-- Type: UNDO
-- Name: migrate_elastic_page_id_data
-- Description: Migrate elastic_page_id field from article_id in highlight and article_saving_request tables
BEGIN;
UPDATE omnivore.article_saving_request
SET elastic_page_id = null WHERE elastic_page_id is not NULL;
UPDATE omnivore.highlight
SET elastic_page_id = null WHERE elastic_page_id is not NULL;
COMMIT;