| 1. Which statement distinguishes an Oracle SQL object type from an object instance? Select the one best answer. | |
| Correct answer | |
No valid answer selected. A SQL object type is a schema-level definition. A constructor creates a value of that type. The value can be held temporarily in PL/SQL or persisted by writing it to a table; creating the type alone inserts no business data. Oracle 26ai reference. | |
| 2. Which statement correctly describes what Oracle object-relational features add to a design? Select the one best answer. | |
| Correct answer | |
No valid answer selected. Object types can group named attributes with operations and represent nested values. They extend Oracle's relational facilities. Ordinary relational tables can also represent parent-child relationships, and methods alone do not make object attributes private or enforce every write rule. Oracle 26ai reference. | |
| 3. Which collection types can be created as schema-level SQL types for collection-valued table columns in Oracle 26ai? Select the one best answer. | |
| Correct answer | |
No valid answer selected. VARRAYs and nested tables can be schema-level SQL collection types. PL/SQL also has associative arrays, but those are declared in PL/SQL blocks or packages, not as standalone SQL collection types for table columns. The question concerns SQL collection types, not all three PL/SQL collection families. Oracle 26ai reference. | |
| 4. SALE_HEADER has a nested-table column named DETAIL_NEST. Which query returns each collection element as a separate row? Select the one best answer. | |
| Correct answer | |
No valid answer selected. The TABLE expression unnests a collection into relational rows. Here, s identifies the parent table and d identifies its collection elements. Selecting s.detail_nest alone returns the collection value within its parent result row. This inner unnesting returns no element rows for an empty or null collection. Oracle 26ai reference. | |
| 5. An initialized PL/SQL nested table becomes sparse after individual elements are deleted. Which approach visits its remaining elements safely? Select the one best answer. | |
| Correct answer | |
No valid answer selected. Deleting individual elements can leave gaps in a nested table. FIRST and NEXT traverse the indexes that exist; FIRST returns NULL for an empty collection. COUNT counts existing elements and does not guarantee consecutive indexes from 1 through COUNT. Initialize a null collection before using this traversal. Oracle 26ai reference. | |