Skip to main content Link Menu Expand (external link) Document Search Copy Copied

VECTOR() data type

Vector data types store a specified number of floating point values in an array.

These vectors can be compared using the cosine_distance function.




Argument Description Additional information
length An integer value representing the number of elements in the array Cannot have a zero length

Additional information

  • values in the array must be floats
  • vector itself can be null
  • maximum precision is 64-bit float


CREATE TABLE statement with Vector

CREATE TABLE products (_id id, description string, dabed vector(768));