1Z0-060 · Question #96
What is the result of executing a TRUNCATE TABLE command on a table that has Flashback Archiving enabled?
The correct answer is C. The rows in the table are archived, and then truncated. When Flashback Data Archive (FDA / Oracle Total Recall) is enabled on a table, Oracle tracks historical row versions. When a TRUNCATE TABLE is issued on such a table, Oracle first archives the current rows into the flashback archive to preserve the historical record, and then…
Question
What is the result of executing a TRUNCATE TABLE command on a table that has Flashback Archiving enabled?
Options
- AIt fails with the ORA-665610 Invalid DDL statement on history-tracked message
- BThe rows in the table are truncated without being archived.
- CThe rows in the table are archived, and then truncated.
- DThe rows in both the table and the archive are truncated.
How the community answered
(17 responses)- B6% (1)
- C94% (16)
Explanation
When Flashback Data Archive (FDA / Oracle Total Recall) is enabled on a table, Oracle tracks historical row versions. When a TRUNCATE TABLE is issued on such a table, Oracle first archives the current rows into the flashback archive to preserve the historical record, and then removes the rows from the current table. This ensures the audit trail is intact and time-based queries against the archive remain valid after the truncate. Option A is incorrect because TRUNCATE is permitted on FDA-enabled tables (unlike some DDL such as DROP COLUMN, which is blocked). Option B is incorrect because FDA is specifically designed to prevent untracked data loss. Option D is incorrect because the historical archive itself is not touched; only the current table's rows are removed after archiving.
Topics
Community Discussion
No community discussion yet for this question.