remove_session

This commit is contained in:
hjp 2014-01-11 18:44:23 +00:00
parent 404d448634
commit 48ae9b2939
1 changed files with 6 additions and 0 deletions

6
Notes
View File

@ -136,3 +136,9 @@ where file_type = 'f' and checksum is null
and instances.session=sessions.id and instances.session=sessions.id
limit 100000; limit 100000;
remove_session:
select v.id from instances i right outer join versions2 v on
i.version=v.id where i.id is null
is very slow. Do two independent queries and difference via judy?
In any case all the cleanup stuff needs to be outside of the loop.