Skip to content

Commit

Permalink
Merge pull request #4419 from marhar/patch-2
Browse files Browse the repository at this point in the history
Update vss.md. add INSTALL and LOAD to example.
  • Loading branch information
szarnyasg authored Dec 20, 2024
2 parents bb6793e + 069c30a commit 7f74e4e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/extensions/vss.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ See the [announcement blog post]({% post_url 2024-05-03-vector-similarity-search
To create a new HNSW (Hierarchical Navigable Small Worlds) index on a table with an `ARRAY` column, use the `CREATE INDEX` statement with the `USING HNSW` clause. For example:

```sql
INSTALL vss;
LOAD vss;

CREATE TABLE my_vector_table (vec FLOAT[3]);
INSERT INTO my_vector_table SELECT array_value(a, b, c) FROM range(1, 10) ra(a), range(1, 10) rb(b), range(1, 10) rc(c);
CREATE INDEX my_hnsw_index ON my_vector_table USING HNSW (vec);
Expand Down

0 comments on commit 7f74e4e

Please sign in to comment.