* Fix SQLs

* Update SQls

* Update bootstrap/sql/migrations/native/1.3.3/postgres/schemaChanges.sql

* Update bootstrap/sql/migrations/native/1.3.3/mysql/schemaChanges.sql

---------

Co-authored-by: Pere Miquel Brull <peremiquelbrull@gmail.com>
This commit is contained in:
Mohit Yadav 2024-04-11 15:13:16 +05:30 committed by GitHub
parent 8e558a91e1
commit 3dc4a4f3d1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 33 additions and 0 deletions

View File

@ -0,0 +1 @@
-- Nothing to add here. 1.3.3 migrations only needed for postgres

View File

@ -0,0 +1,32 @@
-- change scheduleType to scheduleTimeline, this was failing earlier in 1.3.2 so updating it here
UPDATE installed_apps
SET json = jsonb_set(
json::jsonb,
'{appSchedule}',
jsonb_set(
json->'appSchedule',
'{scheduleTimeline}',
json->'appSchedule'->'scheduleType'
) - 'scheduleType',
true
)
WHERE json->'appSchedule'->>'scheduleType' IS NOT NULL;
delete from apps_extension_time_series;
-- Change systemApp to system, this was failing earlier in 1.3.2 so updating it here
UPDATE installed_apps
SET json = jsonb_set(
json::jsonb,
'{system}',
json->'systemApp'
) - 'systemApp'
WHERE json ? 'systemApp';
UPDATE apps_marketplace
SET json = jsonb_set(
json::jsonb,
'{system}',
json->'systemApp'
) - 'systemApp'
WHERE json ? 'systemApp';