Start Oracle sql updating multiple tables

Oracle sql updating multiple tables

Again, it is not easy to quantify the reason for this speed increase, since the DBA views do not map directly to Oracle tables, but it is clear that temporary table show promise for improving the execution speed of certain types of Oracle SQL queries.

These execution plans are computed by the Oracle cost-based SQL optimizer commonly known as the CBO.

The choice of executions plans made by the Oracle SQL optimizer is only as good as the Oracle statistics.

As you may remember from Chapter 12, these anti-joins can often be replaced with an outer join. Now, we rewrite the same query to utilize temporary tables by selecting the distinct values from each table.

The following section will show you how to test updating, inserting, and deleting the data.

When a SQL statement is executed, the database must convert the query into an execution plan and choose the best way to retrieve the data.

For Oracle, each SQL query has many choices for execution plans, including which index to use to retrieve table row, what order in which to join multiple tables together, and which internal join methods to use (Oracle has nested loop joins, hash joins, star joins, and sort merge join methods).

The prudent use of temporary tables can dramatically improve Oracle SQL performance.