From 44bca3b72676dddd20b634e559e6a1499a480b28 Mon Sep 17 00:00:00 2001 From: Chris Sharp Date: Fri, 26 Sep 2014 14:19:22 -0400 Subject: [PATCH] LP#1374551: Create index on money.billing.voider to speed user merge. Signed-off-by: Chris Sharp Signed-off-by: Ben Shum --- Open-ILS/src/sql/Pg/080.schema.money.sql | 1 + Open-ILS/src/sql/Pg/upgrade/XXXX.index.money_billing.voider.sql | 7 +++++++ 2 files changed, 8 insertions(+) create mode 100644 Open-ILS/src/sql/Pg/upgrade/XXXX.index.money_billing.voider.sql diff --git a/Open-ILS/src/sql/Pg/080.schema.money.sql b/Open-ILS/src/sql/Pg/080.schema.money.sql index 5004f00490..fc0cfe30e8 100644 --- a/Open-ILS/src/sql/Pg/080.schema.money.sql +++ b/Open-ILS/src/sql/Pg/080.schema.money.sql @@ -62,6 +62,7 @@ CREATE TABLE money.billing ( ); CREATE INDEX m_b_xact_idx ON money.billing (xact); CREATE INDEX m_b_time_idx ON money.billing (billing_ts); +CREATE INDEX m_b_voider_idx ON money.billing (voider); -- helps user merge function speed CREATE TABLE money.payment ( id BIGSERIAL PRIMARY KEY, diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.index.money_billing.voider.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.index.money_billing.voider.sql new file mode 100644 index 0000000000..71fd2209a0 --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.index.money_billing.voider.sql @@ -0,0 +1,7 @@ +BEGIN; + +SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version); + +CREATE INDEX m_b_voider_idx ON money.billing (voider); + +COMMIT; -- 2.11.0