1Z0-184-25 practice question 11 of 15

You are asked to fetch the top five vectors nearest to a query vector, but only for a specific category of documents. Which query structure should you use?

Full set: 60 questions
Answer options
A: Use UNION ALL with vector operations
B: Perform the similarity search without a WHERE clause
C: Apply relational filters and a similarity search in the query Correct answer
D: Use VECTOR_INDEX_HINT and NO WHERE clause
Correct Answer:
C. Apply relational filters and a similarity search in the query
Explanation

To fetch the top five nearest vectors for a specific category, combine relational filtering (e.g., WHERE category = 'X') with similarity search (C) (e.g., VECTOR_DISTANCE with ORDER BY and FETCH FIRST 5 ROWS). UNION ALL (A) is for combining result sets, not filtering. Omitting WHERE (B) ignores the category constraint. VECTOR_INDEX_HINT (D) influences index usage, not filtering, and skipping WHERE misses the requirement. Oracle’s vector search examples use WHERE clauses with similarity functions for such tasks.
Reference:Oracle Database 23ai AI Vector Search Guide, Section on Querying Vectors.

Scroll to Top