mirror of
https://codeberg.org/PostERG/xamxam.git
synced 2026-05-06 19:19:19 +02:00
feat: extract MediaController, wire into Dispatcher, delete media.php
This commit is contained in:
8
app/storage/migrations/006_add_composite_index.sql
Normal file
8
app/storage/migrations/006_add_composite_index.sql
Normal file
@@ -0,0 +1,8 @@
|
||||
-- Migration 006: Add composite covering index (is_published, year DESC) on theses
|
||||
--
|
||||
-- Every public-facing query filters on is_published = 1 AND orders/filters by year.
|
||||
-- The existing separate idx_theses_published and idx_theses_year force the query
|
||||
-- planner to pick one index and sort the other via a temp B-tree.
|
||||
-- This single covering index eliminates the extra sort pass.
|
||||
|
||||
CREATE INDEX IF NOT EXISTS idx_theses_pub_year ON theses(is_published, year DESC);
|
||||
Reference in New Issue
Block a user