1Z0-184-25 practice question 9 of 15

Which SQL statement correctly adds a VECTOR column named "v" with 4 dimensions and FLOAT32 format to an existing table named "my_table"?

Full set: 60 questions
Answer options
A: ALTER TABLE my_table MODIFY (v VECTOR(4, FLOAT32))
B: ALTER TABLE my_table ADD (v VECTOR(4, FLOAT32)) Correct answer
C: UPDATE my_table SET v = VECTOR(4, FLOAT32)
D: ALTER TABLE my_table ADD v VECTOR(4, FLOAT32)
Correct Answer:
B. ALTER TABLE my_table ADD (v VECTOR(4, FLOAT32))
Explanation

To add a new column to an existing table, Oracle uses the ALTER TABLE statement with the ADD clause. Option B, ALTER TABLE my_table ADD (v VECTOR(4, FLOAT32)), correctly specifies the column name "v", the VECTOR type, and its attributes (4 dimensions, FLOAT32 precision) within parentheses, aligning with Oracle’s DDL syntax for VECTOR columns. Option A uses MODIFY, which alters existing columns, not adds new ones, making it incorrect here. Option C uses UPDATE, a DML statement for updating data, not a DDL operation for schema changes. Option D omits parentheses around the VECTOR specification, which is syntactically invalid as Oracle requires dimensions and format to be enclosed. The SQL Language Reference confirms this syntax for adding VECTOR columns.
Reference:Oracle Database 23ai SQL Language Reference, Section on ALTER TABLE.

Scroll to Top