plsql-cop-cli icon indicating copy to clipboard operation
plsql-cop-cli copied to clipboard

Parse error when using new row_limiting_clause for similarity searches

Open PhilippSalvisberg opened this issue 1 year ago • 0 comments

The following query causes a parser error:

select name, embedding
  from galaxies
 order by vector_distance(embedding, vector('[0,1,1,0,0]', 5, int8), dot)
 fetch approx first 3 rows only
  with target accuracy 80 percent;

The reason is the new row_limiting_clause introduced in 23.4 to allow similarity searches. Changes in this clause are not covered by the underlying parser.

PhilippSalvisberg avatar Jul 03 '24 08:07 PhilippSalvisberg