Add coalesce to template version migration (#2764)

This commit is contained in:
Miguel de la Cruz 2022-04-12 14:47:45 +02:00 committed by GitHub
parent 0355e1c7d7
commit c5f8b7f142
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -228,7 +228,7 @@ CREATE TABLE {{.prefix}}boards_history (
COALESCE(title, ''),
json_extract(fields, '$.description'),
json_extract(fields, '$.icon'), json_extract(fields, '$.showDescription'), json_extract(fields, '$.isTemplate'),
json_extract(fields, '$.templateVer'),
COALESCE(json_extract(fields, '$.templateVer'), 0),
'{}', json_extract(fields, '$.cardProperties'), json_extract(fields, '$.columnCalculations'), create_at,
update_at, delete_at
FROM {{.prefix}}blocks
@ -239,7 +239,7 @@ CREATE TABLE {{.prefix}}boards_history (
COALESCE(title, ''),
json_extract(fields, '$.description'),
json_extract(fields, '$.icon'), json_extract(fields, '$.showDescription'), json_extract(fields, '$.isTemplate'),
json_extract(fields, '$.templateVer'),
COALESCE(json_extract(fields, '$.templateVer'), 0),
'{}', json_extract(fields, '$.cardProperties'), json_extract(fields, '$.columnCalculations'), create_at,
update_at, delete_at
FROM {{.prefix}}blocks_history