For the complete site map for agents, see llms.txt.
Where the open-source database community meets: Secure your spot at PerconaLive.com
Back to all talks

VECTOR_DISTANCE - Similarity Search in MySQL

Event: November 2026 MySQL Contributor Summit

Dates: November 4, 2026 – November 5, 2026

Presentation: November 4, 2026

Video: Watch video

Link: On event website

Speaker: Cătălin Beșleagă

Proposed MySQL vector distance functions let you compare embeddings and run similarity search in SQL, without exporting the data to another system.

DISTANCE() and its synonym VECTOR_DISTANCE() take two vectors and a metric: Euclidean, squared Euclidean, cosine, dot product, or Manhattan. The functions check that the vectors match in dimension and length and reject invalid numbers. The implementation keeps results consistent across CPU architectures and calculates distances with scalar, AVX2, and AVX-512 kernels.

Isolated benchmarks show about a fivefold to tenfold speedup. End-to-end SQL gains depend on the vector size and on how much of the query time is the distance calculation. This is a pull request for MySQL, not a feature in MySQL Community Edition yet. Windows support and a vector index are still open.

Video

Event

Speaker card

VECTOR_DISTANCE - Similarity Search in MySQL

Speakers