OptApply | SQL Request and Transaction Processing | Teradata Vantage - 17.10 - OptApply - Advanced SQL Engine - Teradata Database

Teradata Vantageā„¢ - SQL Request and Transaction Processing

Advanced SQL Engine
Teradata Database
Release Number
Release Date
July 2021
Content Type
Programming Reference
User Guide
Publication ID
English (United States)

OptApply reformats plastic steps into concrete steps. For definitions of these types of steps, see Generator.

Data from a USING data parcel is set in a parameterized PK request, if present, into the concrete steps. For other parameterized requests, the Parameterized Value Peek subsystem may place USING data into the parse tree prior to the Query Rewrite/Optimizer phases of request processing. If not peeked, or if there are dynamically parameterized literals, parameterized data is attached as part of the concrete step.

Concrete steps are passed to the Dispatcher, which then distributes them to the AMPs via the BYNET.

For more information on the Parameterized Value Peek subsystem, see Parameterized Requests. For more information on dynamic parameterization of literals, see Dynamically Parameterized Requests.

The OptApply component of the Parser engages in the following processing stages:

  1. OptApply receives the plastic steps for a request from the request cache or from the Generator.
  2. The plastic steps are compiled into executable machine code.
  3. OptApply retrieves any data parcels associated with the request parcel and applies them to the plastic steps, creating concrete steps.

    Concrete steps are also referred to as AMP steps.

    For any simple data-driven iterative insert request, the system optimizes the operation by processing multiple insert operations in a single AMP step.

    Note that the system performs this optimization only for simple iterated insert requests.

  4. The concrete steps are sent to the Dispatcher, which sends them across the BYNET to the AMPs.