From: Galen Charlton Date: Tue, 13 Jun 2017 20:52:37 +0000 (+0000) Subject: more SQL fixes X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=cc534f920a583037e76f5d06a8e3a721dcbdc72d;p=working%2FEvergreen.git more SQL fixes Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/src/sql/Pg/950.data.seed-values.sql b/Open-ILS/src/sql/Pg/950.data.seed-values.sql index b2d3867f27..440a6096c8 100644 --- a/Open-ILS/src/sql/Pg/950.data.seed-values.sql +++ b/Open-ILS/src/sql/Pg/950.data.seed-values.sql @@ -17231,7 +17231,7 @@ csht http://id.loc.gov/vocabulary/subjectSchemes/csht Chinese subject headings -- ' ...blah INSERT INTO authority.thesaurus (code, uri, name, control_set) - SELECT code, uri, name, 1 FROM thesausi; + SELECT code, uri, name, 1 FROM thesauri; UPDATE authority.thesaurus SET short_code = 'a' WHERE code = 'lcsh'; UPDATE authority.thesaurus SET short_code = 'b' WHERE code = 'lcshac'; @@ -17247,9 +17247,9 @@ UPDATE authority.thesaurus WHERE short_code IS NULL; INSERT INTO config.i18n_core (fq_field, identity_value, translation, string ) - SELECT 'at.name', t.code, each.key, each.value + SELECT 'at.name', t.code, (xlate).key, (xlate).value FROM thesauri t, - JOIN LATERAL each(t.xlate) ON TRUE + JOIN LATERAL each(t.xlate) AS xlate ON TRUE WHERE NOT EXISTS (SELECT id FROM config.i18n_core diff --git a/Open-ILS/src/sql/Pg/upgrade/YYYY.schema.thesauri.sql b/Open-ILS/src/sql/Pg/upgrade/YYYY.schema.thesauri.sql index cd4875a4ed..84566cbbd8 100644 --- a/Open-ILS/src/sql/Pg/upgrade/YYYY.schema.thesauri.sql +++ b/Open-ILS/src/sql/Pg/upgrade/YYYY.schema.thesauri.sql @@ -428,9 +428,9 @@ UPDATE authority.thesaurus AND control_set = 1; INSERT INTO config.i18n_core (fq_field, identity_value, translation, string ) - SELECT 'at.name', t.code, each.key, each.value + SELECT 'at.name', t.code, (xlate).key, (xlate).value FROM thesauri t, - JOIN LATERAL each(t.xlate) ON TRUE + JOIN LATERAL each(t.xlate) AS xlate ON TRUE WHERE NOT EXISTS (SELECT id FROM config.i18n_core