1Z0-052 · Question #33
You plan to move data from a flat file to a table in your database. You decide to use SQL*Loader direct path load method to perform this task. The table in which you plan to load data in an…
The correct answer is B. UNIQUE C. NOT NULL D. PRIMARY KEY. SQL*Loader direct path load bypasses the SQL engine, so Oracle disables CHECK and FOREIGN KEY constraints by default but keeps NOT NULL, UNIQUE, and PRIMARY KEY constraints enabled.
Question
You plan to move data from a flat file to a table in your database. You decide to use SQL*Loader direct path load method to perform this task. The table in which you plan to load data in an important table having various integrity constraint defined on it. Which constraints will remain enabled by default during this operation? (Choose all that apply.)
Options
- ACHECK
- BUNIQUE
- CNOT NULL
- DPRIMARY KEY
- EFOREIGN KEY
How the community answered
(72 responses)- A6% (4)
- B82% (59)
- E13% (9)
Why each option
SQL*Loader direct path load bypasses the SQL engine, so Oracle disables CHECK and FOREIGN KEY constraints by default but keeps NOT NULL, UNIQUE, and PRIMARY KEY constraints enabled.
CHECK constraints are disabled by default during direct path load because evaluating CHECK expressions requires the SQL engine, which is bypassed in this mode.
UNIQUE constraints remain enabled during a direct path load because Oracle validates uniqueness against existing rows at the end of the load operation, ensuring no duplicate keys are inserted.
NOT NULL constraints are enforced record-by-record during direct path load because Oracle checks each incoming value as it writes data blocks, rejecting rows with missing required values.
PRIMARY KEY constraints remain enabled because a PRIMARY KEY is logically a combination of UNIQUE and NOT NULL, both of which are enforced during direct path load as described above.
FOREIGN KEY constraints are disabled by default during direct path load because referential integrity lookups require SQL engine processing that is skipped when writing directly to data blocks.
Concept tested: SQL*Loader direct path load constraint handling
Source: https://docs.oracle.com/en/database/oracle/oracle-database/19/sutil/oracle-sql-loader-conventional-and-direct-loads.html
Topics
Community Discussion
No community discussion yet for this question.