Force timestamp check into join condition
authorMagnus Hagander <magnus@hagander.net>
Tue, 17 Aug 2021 10:38:28 +0000 (12:38 +0200)
committerMagnus Hagander <magnus@hagander.net>
Tue, 17 Aug 2021 10:38:28 +0000 (12:38 +0200)
commit0277291830a3b74cb184d14815633d6be9646bf5
tree979aecf7ee59987afc4ba7b06305019eaf8c01b5
parentf9dfbcab4c9a0fa6fd3d7eeb241ba662944d3d2a
Force timestamp check into join condition

Unfortunately, 6c44b60 very clearly de-optimized the query when running
on a system with millions of log-rows. Oops. So force the django ORM to
put the filter on the join clause thereby making it possible to use an
index, which should make it actually optimized.
hamnadmin/hamnadmin/register/views.py