WordPress Developer Ukraine, Kyiv
MySQL 9.0 Features: VECTOR Type and JavaScript Stored Programs

MySQL 9.0 Features: VECTOR Type and JavaScript Stored Programs

MySQL 8.4 LTS and 9.x for WordPress hosts: what changes, what to wait for MySQL changed its release model in 2024: Long-Term Support releases (8.4, released April 2024) for production, and Innovation releases (9.0, 9.1, …) every few months with new features and a short support window. MySQL 8.0 reached its end of life in…
MySQL InnoDB Locking: Deadlocks, Gap Locks, and How to Avoid Them

MySQL InnoDB Locking: Deadlocks, Gap Locks, and How to Avoid Them

InnoDB locks and deadlocks in WordPress: read the error, fix the order “Deadlock found when trying to get lock; try restarting transaction” appears in a WordPress log mostly on busy WooCommerce shops and in plugins that update counters or custom tables in transactions. InnoDB detects the deadlock and rolls back one of the transactions, so…
MySQL Common Table Expressions: Recursive Queries for Hierarchical Data

MySQL Common Table Expressions: Recursive Queries for Hierarchical Data

Recursive CTEs: query category trees and page hierarchies in MySQL WordPress stores hierarchies as parent pointers: a page has a post_parent, a category a parent in wp_term_taxonomy. Finding all descendants of an item needs one query per level in PHP, or a function like get_term_children() that loads the whole taxonomy into memory. A recursive common…
MySQL Binary Log and Point-in-Time Recovery for WordPress

MySQL Binary Log and Point-in-Time Recovery for WordPress

Point-in-time recovery for WordPress with the MySQL binary log A nightly backup protects against losing everything, but not against losing a day. When a faulty plugin update or a wrong DELETE destroys data at 15:42, restoring last night’s dump also throws away every order and comment since midnight. MySQL’s binary log records every change; with…
MySQL GENERATED Columns: Virtual Indexes and JSON Extraction

MySQL GENERATED Columns: Virtual Indexes and JSON Extraction

MySQL generated columns: index values that are computed or inside JSON A query that filters on LOWER(email), on DATE(created_at) or on a key inside a JSON document cannot use a normal index: the index stores the column, not the result of the expression. A generated column stores (or computes) that expression as a column of…
MySQL Table Partitioning for Large WordPress Databases

MySQL Table Partitioning for Large WordPress Databases

MySQL partitioning for large WordPress log tables Partitioning splits a table into separate physical parts by a rule, for example one part per month, while queries still see one table. For WordPress, the useful case is not wp_posts or wp_postmeta, but the large append-only tables that plugins create: logs, statistics, events. There, partitions make old…