When a SQL query request is submitted to the Teradata Database Server, the following steps occur:
- Parsing Engine performs the following:
- Parser - Searches the Request Cache if the request is already there.
- Syntaxer - Checks the syntax of the request.
- Resolver - Resolves object names(Database,Table,etc.) to internal identifiers from the Data Dictionary
- Security - Checks the Data Dictionary for all the necessary privileges.
- Optimizer
- Optimize - It determines the most cost effective way to process the request.
- Lock - Optimizer checks the request whether to place locks on any object.
- Generator - Transforms the optimized parse tree into plastic steps and caches the steps into the Request Cache if needed.
- gncApply - Binds in parameterized data if exists and transforms plastic steps into concrete steps.
- Dispatcher performs the following:
- Receive - Receives concrete steps
- Dispatch - Places the first step on the BYNET and tells the BYNET whether this step is for one/several/all AMPs and waits for completion response.
- Response - Receives completion response from all the expected AMPs and places the next step on the BYNET. This continues until all steps are complete.
- AMPs - AMPs pick up the steps from the BYNET and processes the step.