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

SQL Request and Transaction Processing

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-24
dita:mapPath
ykx1561500561173.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1142
lifecycle
previous
Product Category
Teradata Vantageā„¢

The Generator formulates the AMP processing steps based on the optimized parse tree plan it receives as the output of the Optimizer. These steps are called plastic steps, contain column and row information, but no data parcel values, and are later transformed into concrete steps by OptApply.

Plastic Steps and Concrete Steps

Plastic Steps
Plastic steps are the output of the Generator. Except for any hard-coded literal values that may be used, the plastic steps contain column and row information, but do not have any data parcel values associated with them. Plastic steps can be cached for potential reuse.
A single request parcel can generate many plastic steps.
Plastic steps allow data values from a data parcel in a parameterized-independent request to be inserted into the optimized query plan by OptApply. For more information on parameterized requests, see Parameterized Requests and Dynamically Parameterized Requests.
Concrete Steps
Concrete steps are the output of OptApply. They are context- and data-laden AMP directives that contain user- and session-specific information in addition to data parcels.
Each concrete step is composed of the following parts:
  • System message header

    Contains the message class and kind, length, logical host identifier, session and request number, version number, and character set code.

  • Common step header

    Contains account numbers and routing information. Specifies who is to receive the step, what should be done with the responses generated by the step, how the AMPs signal task completion, and what is the context for the step (for example, a transaction number).

  • Step components

    A series of operation-dependent fields including step flags and the step mode.

  • Data

    Contained in a varying length data area.

Generator Processes

The Generator performs the following processes:

  1. The Generator receives the optimized parse tree from the Optimizer and uses it to build plastic steps.
  2. Each step is created with a step header containing fixed information about the step and the component of the step, which is the actual context-free AMP directive.
  3. The plastic steps are cached, as determined by the request caching logic.
  4. The plastic steps are then sent to OptApply.