kemono2/db/migrations/20210328_01_8tlz4-add-indexes-to-favorites-tables.py

21 lines
350 B
Python
Raw Normal View History

2024-07-04 21:57:05 +02:00
"""
Add indexes to favorites tables
"""
from yoyo import step
__depends__ = {"20210322_01_In37S-add-account-field"}
steps = [
step(
"""
CREATE INDEX ON account_artist_favorite (service, artist_id)
"""
),
step(
"""
CREATE INDEX ON account_post_favorite (service, artist_id, post_id)
"""
),
]