-- Can be removed/skipped if there were no schema changes.
SELECT auditor.update_auditors();
-\qecho
-\qecho This is a partial record attribute reingest of your bib records.
-\qecho It may take a while.
-\qecho You may cancel now without losing the effect of the rest of the
-\qecho upgrade script, and arrange the reingest later.
-SELECT COUNT(metabib.reingest_record_attributes(bre.id))
- FROM biblio.record_entry bre
- JOIN metabib.record_attr_flat mraf ON (bre.id = mraf.id)
- WHERE deleted IS FALSE
- AND attr = 'item_type'
- AND value = 'g';
+--\qecho
+--\qecho This is a partial record attribute reingest of your bib records.
+--\qecho It may take a while.
+--\qecho You may cancel now without losing the effect of the rest of the
+--\qecho upgrade script, and arrange the reingest later.
+--SELECT COUNT(metabib.reingest_record_attributes(bre.id))
+-- FROM biblio.record_entry bre
+-- JOIN metabib.record_attr_flat mraf ON (bre.id = mraf.id)
+-- WHERE deleted IS FALSE
+-- AND attr = 'item_type'
+-- AND value = 'g';
+++ /dev/null
-BEGIN;
-
-
--- add hopeless olds fix
---SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-
-INSERT INTO config.workstation_setting_type (name, grp, datatype, label)
-VALUES (
- 'eg.orgselect.hopeless.wide_holds', 'gui', 'integer',
- oils_i18n_gettext(
- 'eg.orgselect.hopeless.wide_holds',
- 'Default org unit for hopeless holds interface',
- 'cwst', 'label'
- )
-);
-
-
--- add dewey range reports view
---SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-
-CREATE OR REPLACE VIEW reporter.asset_call_number_dewey AS
- SELECT id AS call_number,
- call_number_dewey(label) AS dewey,
- CASE
- WHEN call_number_dewey(label) ~ '^[0-9][0-9.]*$'::text THEN btrim(to_char(10::double precision * floor(call_number_dewey(label)::double precision / 10::double precision), '000'::text))
- ELSE NULL::text
- END AS dewey_block_tens,
- CASE
- WHEN call_number_dewey(label) ~ '^[0-9][0-9.]*$'::text THEN btrim(to_char(100::double precision * floor(call_number_dewey(label)::double precision / 100::double precision), '000'::text))
- ELSE NULL::text
- END AS dewey_block_hundreds,
- CASE
- WHEN call_number_dewey(label) ~ '^[0-9][0-9.]*$'::text THEN (btrim(to_char(10::double precision * floor(call_number_dewey(label)::double precision / 10::double precision), '000'::text)) || '-'::text) || btrim(to_char(10::double precision * floor(call_number_dewey(label)::double precision / 10::double precision) + 9::double precision, '000'::text))
- ELSE NULL::text
- END AS dewey_range_tens,
- CASE
- WHEN call_number_dewey(label) ~ '^[0-9][0-9.]*$'::text THEN (btrim(to_char(100::double precision * floor(call_number_dewey(label)::double precision / 100::double precision), '000'::text)) || '-'::text) || btrim(to_char(100::double precision * floor(call_number_dewey(label)::double precision / 100::double precision) + 99::double precision, '000'::text))
- ELSE NULL::text
- END AS dewey_range_hundreds
- FROM asset.call_number
- WHERE call_number_dewey(label) ~ '^[0-9]'::text;
-
-
---SELECT evergreen.upgrade_deps_block_check('1238', :eg_version);
-
-INSERT INTO permission.perm_list ( id, code, description ) VALUES
- ( 625, 'VIEW_BOOKING_RESERVATION', oils_i18n_gettext(625,
- 'View booking reservations', 'ppl', 'description')),
- ( 626, 'VIEW_BOOKING_RESERVATION_ATTR_MAP', oils_i18n_gettext(626,
- 'View booking reservation attribute maps', 'ppl', 'description'))
-;
-
-COMMIT;
+++ /dev/null
-begin;
-
-
--- SELECT COUNT(*), workstation, name FROM actor.workstation_setting
--- GROUP BY 2, 3 HAVING COUNT(*) > 1;
-
--- we need to dedupe our workstation settings to prepare for the new index
-create table actor.workstation_setting_temp (like actor.workstation_setting);
-insert into actor.workstation_setting_temp select * from actor.workstation_setting;
-truncate actor.workstation_setting;
-insert into actor.workstation_setting (select distinct on (workstation, name) id, workstation, name, value from actor.workstation_setting_temp);
-drop table actor.workstation_setting_temp;
-
--- change the id number for ADMIN_OPENATHENS
-delete from permission.grp_perm_map where perm = 620;
-delete from permission.perm_list where id = 620;
-insert into permission.perm_list (code, description) values ('ADMIN_OPENATHENS', 'Allow a user to administer OpenAthens authentication service');
-insert into permission.grp_perm_map (grp, perm, depth, grantable) values (32, (select id from permission.perm_list where code = 'ADMIN_OPENATHENS'), 0, false);
-
-commit;