Meta Query Performance Gotchas
meta_query joins the postmeta table once per meta clause. Three meta clauses means three joins on a typically un-indexed table.Add a database index on (meta_key, meta_value(40)) fo…
Read article →meta_query joins the postmeta table once per meta clause. Three meta clauses means three joins on a typically un-indexed table.Add a database index on (meta_key, meta_value(40)) fo…
Read article →When postmeta queries dominate your slow log, it is time for a custom table. dbDelta() with a CREATE TABLE statement on activation, then $wpdb queries…
Read article →A backup you have not tested is not a backup. Schedule monthly restores into a staging environment — automate the verification.For Postgres, pg_dump for logical…
Read article →Three-phase pattern for schema changes: add the new column, dual-write to both, backfill in batches, switch reads, drop the old column. Each phase is independently…
Read article →