X-Git-Url: http://git.equinoxoli.org/?p=migration-tools.git;a=blobdiff_plain;f=remove_ou_data%2FREADME;h=24728be9063ad35f4f4ce5c29cbba9891dadfe11;hp=c740409c18ccf1426b392856e003ef7f622a2676;hb=b4a45202fa9b19f2e38c22bafa36388d1e004dfe;hpb=c919228a7234c1fdfa9f9cfbae245fc30731eb85 diff --git a/remove_ou_data/README b/remove_ou_data/README index c740409..24728be 100644 --- a/remove_ou_data/README +++ b/remove_ou_data/README @@ -3,18 +3,10 @@ remove data belonging to an OU and its descendants in an Evergreen database. Each script uses a variable called ou_to_del that should be set to the shortname of the OU to remove. -Generate script to delete users: - -SELECT 'DELETE FROM actor.usr WHERE id = ' || id || ';' -FROM actor.usr WHERE home_ou IN ( - SELECT (actor.org_unit_descendants(id)).id FROM actor.org_unit - WHERE shortname = 'EXAMPLE' -); - After running through the scripts, it should be possible to remove the actor.org_unit entries themselves. TODO: +-- remove some reporter folders/reports/schedules -- remove event output that is no longer associated with any events --- remvoe user address auditor entries