temptours+tours
This commit is contained in:
12
engine/engine_components/lectures.py
Normal file
12
engine/engine_components/lectures.py
Normal file
@ -0,0 +1,12 @@
|
||||
from engine.constants import BATCH_SIZE
|
||||
|
||||
def get_new_lectures(cur, last_processed: int):
|
||||
sql = """
|
||||
SELECT rcourse_id, chrinfo_tag, chrinfo_time, chrinfo_location
|
||||
FROM reader_lectures
|
||||
WHERE rcourse_id > %s
|
||||
ORDER BY rcourse_id ASC
|
||||
LIMIT %s
|
||||
"""
|
||||
cur.execute(sql, (last_processed, BATCH_SIZE))
|
||||
return cur.fetchall()
|
||||
Reference in New Issue
Block a user