

On commit fire, on complete transaction, data remain perserved in this it only lost at end of session or manually delete. On commit fire it will complete transaction and table data is deleted.ĬREATE GLOBAL TEMPORARY TABLE TEST_TEMP (id NUMBER) ON COMMIT PRESERVE ROWS Only be removed at the end of the session or manually delete command.Įxample: Use of Clauses in Temporary table.ĬREATE GLOBAL TEMPORARY TABLE TEST_TEMP (id NUMBER) ON COMMIT DELETE ROWS Clause make sure data deleted at the end of the transaction or the end of the session level. Global Temporary Table has two options: 1. Data is remain private at session level.Ĭlause make sure data deleted at the end of the transaction or the end of the session level.Ĭlause make sure data remain persistent at the end of the transaction. Oracle does not support Local Temporary table. Oracle does not support Local Temporary table. there are a lot of ORA-00600 errors known when using global temporary tables in XA transactions. Users can gather statistics on GTT and can have own version of session statistics. the usage of temporary tables is not supported in distributed transactions. Starting with 12c we can set the table-level preference GLOBALTEMPTABLESTATS to either shared or session-specific (global preference default GLOBALTEMPTABLESTATS to SESSION). Temporary table is used to store data temporary for a session and utilized in single session or transaction as you needed and defined while creating Temporary table in Oracle.ġ. I found Note 1051543.1 'Known issues with Global Temporary Tables and Distributed or XA transactions' on Oracle Metalink stating.

Global and local temporary table in Oracle
