Purpose
The END LOADING command distributes all of the rows that were sent from the client to the Teradata Database during the loading phase to their final destination on the AMPs.
Syntax
Usage Notes
Table 31 describes the things to consider when using the END LOADING command.
Topic |
Usage Notes |
End Loading Phase |
The END LOADING command begins the end loading phase of a Teradata FastLoad job. During this phase, all rows are distributed on the AMPs and stored in the final Teradata FastLoad table. When the end loading phase completes, the Teradata Database removes the access locks that were placed on the three tables specified in the BEGIN LOADING command so users with the proper privileges can access them using Teradata SQL statements. |
Entering Teradata SQL Statements |
Many of the Teradata SQL statements from Teradata FastLoad cannot be entered because the utility supports only a subset of the Teradata SQL language. So, when END LOADING has completed and access to data stored in the Teradata FastLoad table or the error tables is required, it cannot be done from Teradata FastLoad. You must use BTEQ or a similar application program must be used to query these tables. |
Error Tables |
Teradata FastLoad automatically drops error tables that contain no rows when END LOADING finishes executing. |
Internal Checkpointing |
The Teradata Database uses internal checkpointing while processing an END LOADING command. Therefore, a job can be interrupted during the end loading phase without disturbing processing status. When the job is restarted, the Teradata Database resumes processing from where it left off. |
Example
The following command example completes a Teradata FastLoad job:
END LOADING ;
The Teradata FastLoad completion message for the END LOADING command depends on whether the job includes a RECORD command.
Table 32 describes the possible RECORD command Completion messages.
Job |
Teradata FastLoad Response Layout |
If the Job includes a RECORD command |
Total Records Read = 500
‑ skipped by RECORD command = 50
‑ sent to the RDBMS = 450
Total Error Table 1 = 25
Total Error Table 2 = 0
Total Inserts Applied = 425
Total Duplicate Rows = 0
|
If the Job does not include a RECORD command |
Total Records Read = 500
Total Error Table 1 = 25
Total Error Table 2 = 0
Total Inserts Applied = 475
Total Duplicate Rows = 0
|