diff --git a/deploy/ansible/roles/elasticsearch/files/reindex_nyaapantsu.py b/deploy/ansible/roles/elasticsearch/files/reindex_nyaapantsu.py index 4c9abe3c..ff5aa206 100644 --- a/deploy/ansible/roles/elasticsearch/files/reindex_nyaapantsu.py +++ b/deploy/ansible/roles/elasticsearch/files/reindex_nyaapantsu.py @@ -23,7 +23,7 @@ pgconn = psycopg2.connect(dbparams) cur = pgconn.cursor() # We MUST use NO QUERY CACHE because the values are insert on triggers and # not through pgppool. -cur.execute("""/*NO QUERY CACHE*/ SELECT id, torrent_id, action FROM reindex_torrents""") +cur.execute("""/*NO QUERY CACHE*/ SELECT reindex_torrents_id, torrent_id, action FROM reindex_torrents""") fetches = cur.fetchmany(CHUNK_SIZE) while fetches: