MySQL HeatWave User Guide

5.3.13 Vector Functions

The following table shows supported vector functions. These are not supported with dictionary-encoded columns. These were introduced in MySQL 9.0.0.

Table 5.12 Vector Functions

Name Description
DISTANCE() Calculates the distance between two vectors with the specified method
VECTOR_TO_STRING() Get the string representation of a VECTOR column, given its value as a binary string
FROM_VECTOR() A synonym for VECTOR_TO_STRING()
TO_VECTOR() A synonym for STRING_TO_VECTOR()
VECTOR_DIM() Get the length of a vector, that is, the number of entries it contains
VECTOR_DISTANCE A synonym for DISTANCE()
VECTOR_TO_STRING() Get the string representation of a VECTOR column, given its value as a binary string

What's Next