Skip to content

Instantly share code, notes, and snippets.

@vinnyjth
Created May 16, 2024 08:42
Show Gist options
  • Save vinnyjth/f3ab2eeab9321c42d6c24412a95f09f4 to your computer and use it in GitHub Desktop.
Save vinnyjth/f3ab2eeab9321c42d6c24412a95f09f4 to your computer and use it in GitHub Desktop.

Diff Summary.

diff File

The diff file describes the net changes across the total DB. You should expect changes to this file to represent intended changes to the shovel output. If you are performing a refactor, with no intended code changes, you should expect no changes to this file.

csv File

The csv file represents all operations that were performed that resulted in a data update. This doesn't including touching a content item (only updating a timestamp), but does include wiping a field out and then restoring that field to it's original contents. It will also track id changes.

Optimally, a dag that is not producing changes should not be wiping/restoring data on a run (should produce an empty csv). Practically, we have a long way to go in this area. Some operations (such as keeping track of content_tags) is easier to do by wiping the table and restoring, which produces operations, but doesn't result in a net diff.

28c28
< 055e97a6-7321-43a8-a311-b476a93fbd52 UT \N \N \N \N Campus 4 ministry_platform \N \N f \N apollos_demo campus
---
> 055e97a6-7321-43a8-a311-b476a93fbd52 UT \N \N \N \N Campus 4 ministry_platform \N \N f 8de51cd2-6e03-4b92-b67b-4c009feeb788 apollos_demo campus
49c49
< c90957dd-5913-45f0-b035-2ca57ee88eab Friends \N \N \N \N Campus 2 ministry_platform \N \N f \N apollos_demo campus
---
> c90957dd-5913-45f0-b035-2ca57ee88eab Friends \N \N \N \N Campus 2 ministry_platform \N \N f 8de51cd2-6e03-4b92-b67b-4c009feeb788 apollos_demo campus
53c53
< d6b957de-809b-440f-8649-c61e58bb7ae4 Campbell 2301 Jacksboro Pike Suite 3 \N LaFollette TN 37766 36.34487 -84.161683 \N \N Campus 5 ministry_platform \N \N f \N apollos_demo campus
---
> d6b957de-809b-440f-8649-c61e58bb7ae4 Campbell 2301 Jacksboro Pike Suite 3 \N LaFollette TN 37766 36.34487 -84.161683 \N \N Campus 5 ministry_platform \N \N f 8de51cd2-6e03-4b92-b67b-4c009feeb788 apollos_demo campus
1450c1450
< IMAGE https://groups-production.s3.amazonaws.com/uploads/group/header_image/defaults/3.png aac5be4a-e6f5-4fbf-9607-ed8962d293d2 Community https://groups-production.s3.amazonaws.com/uploads/group/header_image/defaults/3.png planning_center 32a1f54b-fe00-4489-a2a5-f2a2f7ba5b63 ImageMedia \N \N {} apollos_demo media
---
> IMAGE https://groups-production.s3.amazonaws.com/uploads/group/header_image/defaults/3.png aac5be4a-e6f5-4fbf-9607-ed8962d293d2 Community https://groups-production.s3.amazonaws.com/uploads/group/header_image/defaults/3.png planning_center 32a1f54b-fe00-4489-a2a5-f2a2f7ba5b63 ImageMedia \N \N {"width": 1280, "height": 720} apollos_demo media
1867c1867
< IMAGE https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb cc2f3eb5-725b-40a7-8279-5fb76edb09a5 Campus campusimage-71 rock 8de51cd2-6e03-4b92-b67b-4c009feeb788 IMAGE \N \N {"width": 183, "height": 183} apollos_demo media
---
> IMAGE https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb d6b957de-809b-440f-8649-c61e58bb7ae4 Campus campusimage-71 rock 8de51cd2-6e03-4b92-b67b-4c009feeb788 IMAGE \N \N {"width": 183, "height": 183} apollos_demo media
table_name changed_fields client_query action row_data
node_slug "node_id"=>"442c18bc-dbfc-4675-8cd3-936c97e32d9e" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'giving', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '56' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"a1651f1b-6011-4c04-8535-20475032f11e","slug"=>"giving","node_id"=>"dfac10b4-4794-4069-b949-f5a75a67457a","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"dfac10b4-4794-4069-b949-f5a75a67457a" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'giving', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '55' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"a1651f1b-6011-4c04-8535-20475032f11e","slug"=>"giving","node_id"=>"442c18bc-dbfc-4675-8cd3-936c97e32d9e","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"71fef070-91b3-455b-a10f-32e6865179b3" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'at-the-movies', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '45' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"70381964-236a-40cb-988b-cbb94e8ace59","slug"=>"at-the-movies","node_id"=>"63d6a175-3e2d-4fd3-a252-43a5474e81f4","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"e74ce825-68e9-4626-bfc2-f93a2c28ce16" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', '1x8', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '44' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"d4246052-3359-4667-a5b1-a4044dae5eee","slug"=>"1x8","node_id"=>"d7695dea-6ff0-4cec-883f-7116bb37d917","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"82379b42-03ee-48af-a3df-0d992cce29cc" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'potential', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '43' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"ca3b2b48-c5b8-4b29-878f-198f67a82f28","slug"=>"potential","node_id"=>"a118cdb6-7b7b-4580-9162-d9adb32aa990","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"42132704-a408-4401-a2fb-021088147435" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'arrival', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '41' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"097d5b6f-e6fe-4062-bd6d-a56dda92eaef","slug"=>"arrival","node_id"=>"8a38cdb4-2809-47b4-bc3a-14fce0f29a3a","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"63d6a175-3e2d-4fd3-a252-43a5474e81f4" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'at-the-movies', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '29' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"70381964-236a-40cb-988b-cbb94e8ace59","slug"=>"at-the-movies","node_id"=>"71fef070-91b3-455b-a10f-32e6865179b3","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"d7695dea-6ff0-4cec-883f-7116bb37d917" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', '1x8', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '28' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"d4246052-3359-4667-a5b1-a4044dae5eee","slug"=>"1x8","node_id"=>"e74ce825-68e9-4626-bfc2-f93a2c28ce16","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"a118cdb6-7b7b-4580-9162-d9adb32aa990" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'potential', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '27' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"ca3b2b48-c5b8-4b29-878f-198f67a82f28","slug"=>"potential","node_id"=>"82379b42-03ee-48af-a3df-0d992cce29cc","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
node_slug "node_id"=>"8a38cdb4-2809-47b4-bc3a-14fce0f29a3a" INSERT INTO node_slug (created_at, updated_at, slug, node_type, node_id) SELECT '2024-05-16 08:39:13.242336+00:00', '2024-05-16 08:39:13.242336+00:00', 'arrival', 'ContentItem', content_item.id FROM content_item WHERE origin_id = '25' AND origin_type = 'rock' ON CONFLICT (slug, church_slug) DO UPDATE SET node_id = EXCLUDED.node_id U "id"=>"097d5b6f-e6fe-4062-bd6d-a56dda92eaef","slug"=>"arrival","node_id"=>"42132704-a408-4401-a2fb-021088147435","node_type"=>"ContentItem","church_slug"=>"apollos_demo"
content_tag DELETE FROM content_tag WHERE content_item_id = '8a5d353f-4b13-4f06-80f5-40d813d97c12' AND tag_id IN ('c333d38e-3c1b-4a30-b6f8-ae2c869125af', '3d6fa871-ec87-40d6-8823-f50f1a19b4d9', '00956ae5-3b0f-4457-851e-5b3719bf8322', '1656d19e-f48c-4883-bcb7-f39b6157ef21', 'febfa21e-768e-455c-ae1e-b7a3d8571ac7', '747b6987-8dfc-4c94-bc78-2e5f599bdcd0', '2c43ee60-b841-4c40-b326-5a436ee57db0') D "tag_id"=>"00956ae5-3b0f-4457-851e-5b3719bf8322","church_slug"=>"apollos_demo","content_item_id"=>"8a5d353f-4b13-4f06-80f5-40d813d97c12"
content_tag INSERT INTO content_tag (tag_id, content_item_id, created_at, updated_at) VALUES ('00956ae5-3b0f-4457-851e-5b3719bf8322', '8a5d353f-4b13-4f06-80f5-40d813d97c12', NOW(), NOW()) I "tag_id"=>"00956ae5-3b0f-4457-851e-5b3719bf8322","church_slug"=>"apollos_demo","content_item_id"=>"8a5d353f-4b13-4f06-80f5-40d813d97c12"
media "metadata"=>"{\"width\": 1280, \"height\": 720}" UPDATE media SET metadata = metadata || '{"width": 1280,"height": 720}'::jsonb WHERE id = '32a1f54b-fe00-4489-a2a5-f2a2f7ba5b63'::uuid U "id"=>"32a1f54b-fe00-4489-a2a5-f2a2f7ba5b63","url"=>"https://groups-production.s3.amazonaws.com/uploads/group/header_image/defaults/3.png","type"=>"IMAGE","node_id"=>"aac5be4a-e6f5-4fbf-9607-ed8962d293d2","metadata"=>"{}","node_type"=>"Community","origin_id"=>"https://groups-production.s3.amazonaws.com/uploads/group/header_image/defaults/3.png","apollos_id"=>"ImageMedia:32a1f54b-fe00-4489-a2a5-f2a2f7ba5b63","church_slug"=>"apollos_demo","origin_type"=>"planning_center","apollos_type"=>"ImageMedia"
media "metadata"=>"{}" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type, metadata) VALUES ('ImageMedia','2024-05-16T08:39:46.330068+00:00'::timestamptz,'2024-05-16T08:39:46.330068+00:00'::timestamptz,NULL,NULL,'IMAGE','https://rock.apollos.app/GetImage.ashx?guid=8ee5a840-0a10-44e2-9dbe-214af27c234b',13,'rock','{}') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url, metadata = excluded.metadata U "id"=>"56960838-8b8b-4bed-9db3-cd1fb03ddc43","url"=>"https://rock.apollos.app/GetImage.ashx?guid=8ee5a840-0a10-44e2-9dbe-214af27c234b","type"=>"IMAGE","node_id"=>NULL,"metadata"=>"{\"audio\": {\"codec\": \"ISO/IEC 14496-3 AAC\", \"channels\": 2, \"lossless\": false, \"dataformat\": \"mp4\", \"channelmode\": \"stereo\", \"sample_rate\": 48000, \"bits_per_sample\": 16}, \"sizes\": {}, \"width\": 426, \"height\": 240, \"length\": 488, \"duration\": 488, \"filesize\": 13138402, \"mime_type\": \"video/mp4\", \"dataformat\": \"quicktime\", \"fileformat\": \"mp4\", \"length_formatted\": \"8:08\", \"created_timestamp\": 1613140927}","node_type"=>NULL,"origin_id"=>"13","apollos_id"=>"ImageMedia:56960838-8b8b-4bed-9db3-cd1fb03ddc43","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"ImageMedia"
media "metadata"=>"{}" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type, metadata) VALUES ('ImageMedia','2024-05-16T08:39:46.330068+00:00'::timestamptz,'2024-05-16T08:39:46.330068+00:00'::timestamptz,NULL,NULL,'IMAGE','https://rock.apollos.app/GetImage.ashx?guid=5047381d-0ca9-49f7-9894-699c296baab6',18,'rock','{}') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url, metadata = excluded.metadata U "id"=>"1dbb99d7-8252-4c6b-b7ed-11bf6607e6df","url"=>"https://rock.apollos.app/GetImage.ashx?guid=5047381d-0ca9-49f7-9894-699c296baab6","type"=>"IMAGE","node_id"=>NULL,"metadata"=>"{\"width\": 960, \"height\": 180}","node_type"=>NULL,"origin_id"=>"18","apollos_id"=>"ImageMedia:1dbb99d7-8252-4c6b-b7ed-11bf6607e6df","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"ImageMedia"
media "metadata"=>"{}" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type, metadata) VALUES ('ImageMedia','2024-05-16T08:39:46.330068+00:00'::timestamptz,'2024-05-16T08:39:46.330068+00:00'::timestamptz,NULL,NULL,'IMAGE','https://rock.apollos.app/GetImage.ashx?guid=d00fceaa-2d16-40bf-9ba4-352d42605e28',10,'rock','{}') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url, metadata = excluded.metadata U "id"=>"389ca5bf-0acd-4dc5-98ee-720024f84819","url"=>"https://rock.apollos.app/GetImage.ashx?guid=d00fceaa-2d16-40bf-9ba4-352d42605e28","type"=>"IMAGE","node_id"=>NULL,"metadata"=>"{\"width\": 960, \"height\": 180}","node_type"=>NULL,"origin_id"=>"10","apollos_id"=>"ImageMedia:389ca5bf-0acd-4dc5-98ee-720024f84819","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"ImageMedia"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"b994b102-60e3-4b88-8a42-cf934e317ccc","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"b94491c2-d6a7-4f81-9a1b-bd8066eef62c","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"b94491c2-d6a7-4f81-9a1b-bd8066eef62c","event_id"=>"137a2ca7-6930-4c72-bcf6-68207e76a11b","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"b94491c2-d6a7-4f81-9a1b-bd8066eef62c","event_id"=>"cf31b9a4-d654-4735-9bb6-6e944a987bc3","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"12420811-5040-436b-906d-76d32a80639c","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"12420811-5040-436b-906d-76d32a80639c","event_id"=>"137a2ca7-6930-4c72-bcf6-68207e76a11b","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"12420811-5040-436b-906d-76d32a80639c","event_id"=>"cf31b9a4-d654-4735-9bb6-6e944a987bc3","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"83248c94-f23c-4e45-b868-180d286cb768","event_id"=>"137a2ca7-6930-4c72-bcf6-68207e76a11b","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"fba6e8be-8f8a-4dfc-84ac-6be112efaaf3","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag DELETE FROM event_tag WHERE tag_id IN ( SELECT id FROM tag WHERE origin_type = 'rock' AND origin_id LIKE 'eventAudience-%') D "tag_id"=>"fba6e8be-8f8a-4dfc-84ac-6be112efaaf3","event_id"=>"cf31b9a4-d654-4735-9bb6-6e944a987bc3","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-148' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^2(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"b94491c2-d6a7-4f81-9a1b-bd8066eef62c","event_id"=>"cf31b9a4-d654-4735-9bb6-6e944a987bc3","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-151' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^2(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"fba6e8be-8f8a-4dfc-84ac-6be112efaaf3","event_id"=>"cf31b9a4-d654-4735-9bb6-6e944a987bc3","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-24' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^2(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"12420811-5040-436b-906d-76d32a80639c","event_id"=>"cf31b9a4-d654-4735-9bb6-6e944a987bc3","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-148' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^3(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"b94491c2-d6a7-4f81-9a1b-bd8066eef62c","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-151' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^3(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"fba6e8be-8f8a-4dfc-84ac-6be112efaaf3","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-152' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^3(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"b994b102-60e3-4b88-8a42-cf934e317ccc","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-24' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^3(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"12420811-5040-436b-906d-76d32a80639c","event_id"=>"0956aa78-be42-4d1f-a4b1-eaa45e2b5555","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-148' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^4(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"b94491c2-d6a7-4f81-9a1b-bd8066eef62c","event_id"=>"137a2ca7-6930-4c72-bcf6-68207e76a11b","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-24' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^4(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"12420811-5040-436b-906d-76d32a80639c","event_id"=>"137a2ca7-6930-4c72-bcf6-68207e76a11b","church_slug"=>"apollos_demo"
event_tag INSERT INTO event_tag (event_id, tag_id, created_at, updated_at) SELECT event.id, tag.id, tag.created_at, tag.updated_at FROM event INNER JOIN tag ON tag.origin_id = 'eventAudience-147' AND tag.origin_type = 'rock' WHERE event.origin_id ~ '^4(-\d+)?$' AND event.origin_type = 'rock' ON CONFLICT (tag_id, event_id) DO NOTHING I "tag_id"=>"83248c94-f23c-4e45-b868-180d286cb768","event_id"=>"137a2ca7-6930-4c72-bcf6-68207e76a11b","church_slug"=>"apollos_demo"
media "metadata"=>"{\"audio\": {\"codec\": \"ISO/IEC 14496-3 AAC\", \"channels\": 2, \"lossless\": false, \"dataformat\": \"mp4\", \"channelmode\": \"stereo\", \"sample_rate\": 48000, \"bits_per_sample\": 16}, \"sizes\": {}, \"width\": 426, \"height\": 240, \"length\": 488, \"duration\": 488, \"filesize\": 13138402, \"mime_type\": \"video/mp4\", \"dataformat\": \"quicktime\", \"fileformat\": \"mp4\", \"length_formatted\": \"8:08\", \"created_timestamp\": 1613140927}" UPDATE media SET metadata = metadata::jsonb || '{"filesize": 13138402,"mime_type": "video/mp4","length": 488,"length_formatted": "8:08","width": 426,"height": 240,"fileformat": "mp4","dataformat": "quicktime","audio": {"dataformat": "mp4","codec": "ISO/IEC 14496-3 AAC","sample_rate": 48000,"channels": 2,"bits_per_sample": 16,"lossless": false,"channelmode": "stereo"},"created_timestamp": 1613140927,"sizes": {},"duration": 488}'::jsonb WHERE origin_id = '13' U "id"=>"56960838-8b8b-4bed-9db3-cd1fb03ddc43","url"=>"https://rock.apollos.app/GetImage.ashx?guid=8ee5a840-0a10-44e2-9dbe-214af27c234b","type"=>"IMAGE","node_id"=>NULL,"metadata"=>"{}","node_type"=>NULL,"origin_id"=>"13","apollos_id"=>"ImageMedia:56960838-8b8b-4bed-9db3-cd1fb03ddc43","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"ImageMedia"
media "metadata"=>"{\"width\": 960, \"height\": 180}" UPDATE media SET metadata = metadata || '{"width": 960,"height": 180}'::jsonb WHERE id = '1dbb99d7-8252-4c6b-b7ed-11bf6607e6df'::uuid U "id"=>"1dbb99d7-8252-4c6b-b7ed-11bf6607e6df","url"=>"https://rock.apollos.app/GetImage.ashx?guid=5047381d-0ca9-49f7-9894-699c296baab6","type"=>"IMAGE","node_id"=>NULL,"metadata"=>"{}","node_type"=>NULL,"origin_id"=>"18","apollos_id"=>"ImageMedia:1dbb99d7-8252-4c6b-b7ed-11bf6607e6df","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"ImageMedia"
media "metadata"=>"{\"width\": 960, \"height\": 180}" UPDATE media SET metadata = metadata || '{"width": 960,"height": 180}'::jsonb WHERE id = '389ca5bf-0acd-4dc5-98ee-720024f84819'::uuid U "id"=>"389ca5bf-0acd-4dc5-98ee-720024f84819","url"=>"https://rock.apollos.app/GetImage.ashx?guid=d00fceaa-2d16-40bf-9ba4-352d42605e28","type"=>"IMAGE","node_id"=>NULL,"metadata"=>"{}","node_type"=>NULL,"origin_id"=>"10","apollos_id"=>"ImageMedia:389ca5bf-0acd-4dc5-98ee-720024f84819","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"ImageMedia"
content_tag DELETE from content_tag USING tag WHERE content_tag.content_item_id in ('f5182026-3b3a-4346-8b25-7192eee3920d') AND content_tag.tag_id = tag.id AND (tag.origin_id like 'tag-%' or tag.origin_id like 'category-%') AND tag.origin_type = 'wordpress' D "tag_id"=>"94fb3f2b-bd21-43ec-8eb0-6717521b6e9f","church_slug"=>"apollos_demo","content_item_id"=>"f5182026-3b3a-4346-8b25-7192eee3920d"
content_tag INSERT INTO content_tag (content_item_id, created_at, tag_id, updated_at) VALUES ('f5182026-3b3a-4346-8b25-7192eee3920d','2024-05-16T08:40:14.649758+00:00'::timestamptz,'94fb3f2b-bd21-43ec-8eb0-6717521b6e9f','2024-05-16T08:40:14.649758+00:00'::timestamptz) ON CONFLICT (tag_id, content_item_id) DO UPDATE SET created_at = excluded.created_at, updated_at = excluded.updated_at I "tag_id"=>"94fb3f2b-bd21-43ec-8eb0-6717521b6e9f","church_slug"=>"apollos_demo","content_item_id"=>"f5182026-3b3a-4346-8b25-7192eee3920d"
content_tag DELETE from content_tag USING tag WHERE content_tag.content_item_id in ('3c6ae761-928b-4409-9e05-1cbef1967467','b6060526-b008-4952-bc3d-996cfcd7e971','18cfa8ed-81e4-4874-9fbd-002fb78048bd','8f82eb25-9313-45f4-b922-dd02eae4239e','24b8ce12-1c15-45f6-9553-271f61f8116d') AND content_tag.tag_id = tag.id AND (tag.origin_id like 'tag-%' or tag.origin_id like 'category-%') AND tag.origin_type = 'wordpress' D "tag_id"=>"522a811e-0567-4496-82b4-a7837efd669f","church_slug"=>"apollos_demo","content_item_id"=>"3c6ae761-928b-4409-9e05-1cbef1967467"
content_tag DELETE from content_tag USING tag WHERE content_tag.content_item_id in ('3c6ae761-928b-4409-9e05-1cbef1967467','b6060526-b008-4952-bc3d-996cfcd7e971','18cfa8ed-81e4-4874-9fbd-002fb78048bd','8f82eb25-9313-45f4-b922-dd02eae4239e','24b8ce12-1c15-45f6-9553-271f61f8116d') AND content_tag.tag_id = tag.id AND (tag.origin_id like 'tag-%' or tag.origin_id like 'category-%') AND tag.origin_type = 'wordpress' D "tag_id"=>"522a811e-0567-4496-82b4-a7837efd669f","church_slug"=>"apollos_demo","content_item_id"=>"8f82eb25-9313-45f4-b922-dd02eae4239e"
content_tag DELETE from content_tag USING tag WHERE content_tag.content_item_id in ('3c6ae761-928b-4409-9e05-1cbef1967467','b6060526-b008-4952-bc3d-996cfcd7e971','18cfa8ed-81e4-4874-9fbd-002fb78048bd','8f82eb25-9313-45f4-b922-dd02eae4239e','24b8ce12-1c15-45f6-9553-271f61f8116d') AND content_tag.tag_id = tag.id AND (tag.origin_id like 'tag-%' or tag.origin_id like 'category-%') AND tag.origin_type = 'wordpress' D "tag_id"=>"7956de21-90ea-4ad7-bc5f-83fad3f09270","church_slug"=>"apollos_demo","content_item_id"=>"3c6ae761-928b-4409-9e05-1cbef1967467"
content_tag DELETE from content_tag USING tag WHERE content_tag.content_item_id in ('3c6ae761-928b-4409-9e05-1cbef1967467','b6060526-b008-4952-bc3d-996cfcd7e971','18cfa8ed-81e4-4874-9fbd-002fb78048bd','8f82eb25-9313-45f4-b922-dd02eae4239e','24b8ce12-1c15-45f6-9553-271f61f8116d') AND content_tag.tag_id = tag.id AND (tag.origin_id like 'tag-%' or tag.origin_id like 'category-%') AND tag.origin_type = 'wordpress' D "tag_id"=>"d56907b7-2fa9-423c-8c5f-2492a59e7708","church_slug"=>"apollos_demo","content_item_id"=>"8f82eb25-9313-45f4-b922-dd02eae4239e"
content_tag INSERT INTO content_tag (content_item_id, created_at, tag_id, updated_at) VALUES ('3c6ae761-928b-4409-9e05-1cbef1967467','2024-05-16T08:40:14.649758+00:00'::timestamptz,'522a811e-0567-4496-82b4-a7837efd669f','2024-05-16T08:40:14.649758+00:00'::timestamptz) ON CONFLICT (tag_id, content_item_id) DO UPDATE SET created_at = excluded.created_at, updated_at = excluded.updated_at I "tag_id"=>"522a811e-0567-4496-82b4-a7837efd669f","church_slug"=>"apollos_demo","content_item_id"=>"3c6ae761-928b-4409-9e05-1cbef1967467"
content_tag INSERT INTO content_tag (content_item_id, created_at, tag_id, updated_at) VALUES ('3c6ae761-928b-4409-9e05-1cbef1967467','2024-05-16T08:40:14.649758+00:00'::timestamptz,'7956de21-90ea-4ad7-bc5f-83fad3f09270','2024-05-16T08:40:14.649758+00:00'::timestamptz) ON CONFLICT (tag_id, content_item_id) DO UPDATE SET created_at = excluded.created_at, updated_at = excluded.updated_at I "tag_id"=>"7956de21-90ea-4ad7-bc5f-83fad3f09270","church_slug"=>"apollos_demo","content_item_id"=>"3c6ae761-928b-4409-9e05-1cbef1967467"
content_tag INSERT INTO content_tag (content_item_id, created_at, tag_id, updated_at) VALUES ('8f82eb25-9313-45f4-b922-dd02eae4239e','2024-05-16T08:40:14.649758+00:00'::timestamptz,'522a811e-0567-4496-82b4-a7837efd669f','2024-05-16T08:40:14.649758+00:00'::timestamptz) ON CONFLICT (tag_id, content_item_id) DO UPDATE SET created_at = excluded.created_at, updated_at = excluded.updated_at I "tag_id"=>"522a811e-0567-4496-82b4-a7837efd669f","church_slug"=>"apollos_demo","content_item_id"=>"8f82eb25-9313-45f4-b922-dd02eae4239e"
content_tag INSERT INTO content_tag (content_item_id, created_at, tag_id, updated_at) VALUES ('8f82eb25-9313-45f4-b922-dd02eae4239e','2024-05-16T08:40:14.649758+00:00'::timestamptz,'d56907b7-2fa9-423c-8c5f-2492a59e7708','2024-05-16T08:40:14.649758+00:00'::timestamptz) ON CONFLICT (tag_id, content_item_id) DO UPDATE SET created_at = excluded.created_at, updated_at = excluded.updated_at I "tag_id"=>"d56907b7-2fa9-423c-8c5f-2492a59e7708","church_slug"=>"apollos_demo","content_item_id"=>"8f82eb25-9313-45f4-b922-dd02eae4239e"
media "node_id"=>"c90957dd-5913-45f0-b035-2ca57ee88eab" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type) VALUES ('IMAGE','2024-05-16T08:38:53.811902+00:00'::timestamptz,'2024-05-16T08:38:53.811902+00:00'::timestamptz,'c90957dd-5913-45f0-b035-2ca57ee88eab','Campus','IMAGE','https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb','campusimage-71','rock') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url U "id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788","url"=>"https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb","type"=>"IMAGE","node_id"=>"acfcf9ab-7ead-4111-befb-a8a408e0f342","metadata"=>"{\"width\": 183, \"height\": 183}","node_type"=>"Campus","origin_id"=>"campusimage-71","apollos_id"=>"IMAGE:8de51cd2-6e03-4b92-b67b-4c009feeb788","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"IMAGE"
media "node_id"=>"055e97a6-7321-43a8-a311-b476a93fbd52" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type) VALUES ('IMAGE','2024-05-16T08:38:53.811902+00:00'::timestamptz,'2024-05-16T08:38:53.811902+00:00'::timestamptz,'055e97a6-7321-43a8-a311-b476a93fbd52','Campus','IMAGE','https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb','campusimage-71','rock') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url U "id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788","url"=>"https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb","type"=>"IMAGE","node_id"=>"c90957dd-5913-45f0-b035-2ca57ee88eab","metadata"=>"{\"width\": 183, \"height\": 183}","node_type"=>"Campus","origin_id"=>"campusimage-71","apollos_id"=>"IMAGE:8de51cd2-6e03-4b92-b67b-4c009feeb788","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"IMAGE"
media "node_id"=>"d6b957de-809b-440f-8649-c61e58bb7ae4" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type) VALUES ('IMAGE','2024-05-16T08:38:53.811902+00:00'::timestamptz,'2024-05-16T08:38:53.811902+00:00'::timestamptz,'d6b957de-809b-440f-8649-c61e58bb7ae4','Campus','IMAGE','https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb','campusimage-71','rock') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url U "id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788","url"=>"https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb","type"=>"IMAGE","node_id"=>"055e97a6-7321-43a8-a311-b476a93fbd52","metadata"=>"{\"width\": 183, \"height\": 183}","node_type"=>"Campus","origin_id"=>"campusimage-71","apollos_id"=>"IMAGE:8de51cd2-6e03-4b92-b67b-4c009feeb788","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"IMAGE"
campus "image_id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788" UPDATE campus SET image_id = media.id FROM media WHERE campus.id = '055e97a6-7321-43a8-a311-b476a93fbd52' AND media.origin_id = 'campusimage-71' U "id"=>"055e97a6-7321-43a8-a311-b476a93fbd52","city"=>"","name"=>"UT","state"=>"","active"=>"f","digital"=>NULL,"street1"=>"","street2"=>"","image_id"=>NULL,"latitude"=>NULL,"image_url"=>NULL,"longitude"=>NULL,"origin_id"=>"4","apollos_id"=>"Campus:055e97a6-7321-43a8-a311-b476a93fbd52","church_slug"=>"apollos_demo","origin_type"=>"ministry_platform","postal_code"=>"","apollos_type"=>"Campus"
campus "image_id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788" UPDATE campus SET image_id = media.id FROM media WHERE campus.id = 'd6b957de-809b-440f-8649-c61e58bb7ae4' AND media.origin_id = 'campusimage-71' U "id"=>"d6b957de-809b-440f-8649-c61e58bb7ae4","city"=>"LaFollette","name"=>"Campbell","state"=>"TN","active"=>"f","digital"=>NULL,"street1"=>"2301 Jacksboro Pike Suite 3","street2"=>NULL,"image_id"=>NULL,"latitude"=>"36.34487","image_url"=>NULL,"longitude"=>"-84.161683","origin_id"=>"5","apollos_id"=>"Campus:d6b957de-809b-440f-8649-c61e58bb7ae4","church_slug"=>"apollos_demo","origin_type"=>"ministry_platform","postal_code"=>"37766","apollos_type"=>"Campus"
media "node_id"=>"acfcf9ab-7ead-4111-befb-a8a408e0f342" INSERT INTO media (apollos_type, created_at, updated_at, node_id, node_type, type, url, origin_id, origin_type) VALUES ('IMAGE','2024-05-16T08:38:53.811902+00:00'::timestamptz,'2024-05-16T08:38:53.811902+00:00'::timestamptz,'acfcf9ab-7ead-4111-befb-a8a408e0f342','Campus','IMAGE','https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb','campusimage-71','rock') ON CONFLICT (origin_id, church_slug, origin_type) DO UPDATE SET apollos_type = excluded.apollos_type, created_at = excluded.created_at, updated_at = excluded.updated_at, node_id = excluded.node_id, node_type = excluded.node_type, type = excluded.type, url = excluded.url U "id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788","url"=>"https://rock.apollos.app/GetImage.ashx?guid=4e181881-b156-48b0-be40-54af2b14b3fb","type"=>"IMAGE","node_id"=>"cc2f3eb5-725b-40a7-8279-5fb76edb09a5","metadata"=>"{\"width\": 183, \"height\": 183}","node_type"=>"Campus","origin_id"=>"campusimage-71","apollos_id"=>"IMAGE:8de51cd2-6e03-4b92-b67b-4c009feeb788","church_slug"=>"apollos_demo","origin_type"=>"rock","apollos_type"=>"IMAGE"
campus "image_id"=>"8de51cd2-6e03-4b92-b67b-4c009feeb788" UPDATE campus SET image_id = media.id FROM media WHERE campus.id = 'c90957dd-5913-45f0-b035-2ca57ee88eab' AND media.origin_id = 'campusimage-71' U "id"=>"c90957dd-5913-45f0-b035-2ca57ee88eab","city"=>"","name"=>"Friends","state"=>"","active"=>"f","digital"=>NULL,"street1"=>"","street2"=>"","image_id"=>NULL,"latitude"=>NULL,"image_url"=>NULL,"longitude"=>NULL,"origin_id"=>"2","apollos_id"=>"Campus:c90957dd-5913-45f0-b035-2ca57ee88eab","church_slug"=>"apollos_demo","origin_type"=>"ministry_platform","postal_code"=>"","apollos_type"=>"Campus"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment