From 5ce9fce5d4341dfbb89ec6e3a9c8ac8b13a320f1 Mon Sep 17 00:00:00 2001 From: scottmk Date: Tue, 14 Jul 2009 18:22:34 +0000 Subject: [PATCH] Add tables from the auditor schema to actor.usr_purge_data(). git-svn-id: svn://svn.open-ils.org/ILS/trunk@13589 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/sql/Pg/999.functions.global.sql | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Open-ILS/src/sql/Pg/999.functions.global.sql b/Open-ILS/src/sql/Pg/999.functions.global.sql index a7c8852ca0..d373c0afd8 100644 --- a/Open-ILS/src/sql/Pg/999.functions.global.sql +++ b/Open-ILS/src/sql/Pg/999.functions.global.sql @@ -419,7 +419,6 @@ BEGIN UPDATE acq.purchase_order SET editor = dest_usr WHERE editor = src_usr; -- action.* - DELETE FROM action.circulation WHERE usr = src_usr; UPDATE action.circulation SET circ_staff = dest_usr WHERE circ_staff = src_usr; UPDATE action.circulation SET checkin_staff = dest_usr WHERE checkin_staff = src_usr; @@ -459,6 +458,16 @@ BEGIN UPDATE asset.copy SET editor = dest_usr WHERE editor = src_usr; UPDATE asset.copy_note SET creator = dest_usr WHERE creator = src_usr; + -- auditor.* + DELETE FROM auditor.usr_address_history WHERE id = src_usr; + DELETE FROM auditor.usr_history WHERE id = src_usr; + UPDATE auditor.asset_call_number_history SET creator = dest_usr WHERE creator = src_usr; + UPDATE auditor.asset_call_number_history SET editor = dest_usr WHERE editor = src_usr; + UPDATE auditor.asset_copy_history SET creator = dest_usr WHERE creator = src_usr; + UPDATE auditor.asset_copy_history SET editor = dest_usr WHERE editor = src_usr; + UPDATE auditor.asset_biblio_record_entry_history SET creator = dest_usr WHERE creator = src_usr; + UPDATE auditor.asset_biblio_record_entry_history SET editor = dest_usr WHERE editor = src_usr; + -- biblio.* UPDATE biblio.record_entry SET creator = dest_usr WHERE creator = src_usr; UPDATE biblio.record_entry SET editor = dest_usr WHERE editor = src_usr; -- 2.43.2