Last active
February 6, 2019 20:29
-
-
Save litzinger/01d621d0f7f127fb6ca0861f3e1f8a4c to your computer and use it in GitHub Desktop.
DB Indexes for improved EE performance. Courtesy of @mrw
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ALTER TABLE exp_channel_titles ADD INDEX sticky_order (sticky,entry_date,entry_id); | |
# Even if you don't use sticky, every {exp:channel:entries} tag queries on it. | |
ALTER TABLE exp_category_posts ADD INDEX(cat_id); | |
ALTER TABLE exp_files ADD INDEX file_uploads (upload_location_id,file_name); | |
# Lastly, make sure tables are InnoDB. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment