Teradata SQL Statements - MultiLoad

Teradata MultiLoad Reference

Product
MultiLoad
Release Number
15.00
Language
English (United States)
Last Update
2018-09-27
dita:id
B035-2409
lifecycle
previous
Product Category
Teradata Tools and Utilities

Teradata SQL Statements

Teradata SQL statements define and manipulate the data stored in Teradata Database.

Teradata MultiLoad supports a subset of Teradata SQL statements. As a result, other utilities do not have to be invoked to perform routine database maintenance functions before executing Teradata MultiLoad utility tasks. For example, the supported Teradata SQL statements can be used to:

  • Create the table to load
  • Establish a database as an explicit table name qualifier
  • Add checkpoint specifications to a journal table
  • Table 5 lists the Teradata SQL statements Teradata MultiLoad supports. To use any other Teradata SQL statements, exit Teradata MultiLoad and enter them from another application, such as Basic Teradata Query (BTEQ).

     

    Table 5: Teradata SQL Statements Supported in Teradata MultiLoad 

    Teradata SQL Statement

    Function

    ALTER TABLE

    Changes the column configuration or options of an existing table

    CHECKPOINT

    Adds a checkpoint entry to a journal table

    COLLECT STATISTICS

    Collects statistical data for one or more columns of a table

    COMMENT

    Stores or retrieves a comment string associated with a database object

    CREATE DATABASE

    Creates a new database

    CREATE MACRO

    Creates a new macro

    CREATE TABLE

    Creates a new table

    CREATE VIEW

    Creates a new view

    DATABASE

    Specifies a new default database for the current session

    DELETE

    Removes rows from a table

    DELETE DATABASE

    Removes all tables, views, and macros from a database

    DROP DATABASE

    Drops the definition for an empty database from the Data Dictionary

    DROP TABLE

    Removes a table

    GIVE

    Transfers ownership of a database to another user

    GRANT

    Grants privileges to a database object

    INSERT

    Inserts new rows to a table

    MODIFY DATABASE

    Changes the options of an existing database

    RELEASE MLOAD

    Removes the access locks from the target tables in Teradata Database

    This inhibits any attempts to restart the Teradata MultiLoad job when a Teradata MultiLoad task has been suspended or aborted.

    Note: A RELEASE MLOAD statement must be entered from another application (e.g., BTEQ). A RELEASE MLOAD statement cannot be entered from Teradata MultiLoad.

    RENAME

    Changes the name of an existing table, view, or macro

    REPLACE MACRO
    REPLACE VIEW

    Redefines an existing macro or view

    REVOKE

    Rescinds privileges to a database object

    SET QUERY_BAND

    Identifies type and source of query to determine prioritization of queries

    Note: Teradata MultiLoad parses and prevents the sending of the “SET QUERY_BAND ... FOR TRANSACTION;” statement to Teradata Database.

    SET SESSION COLLATION

    Overrides the collation specification for the current session

    SET SESSION OVERRIDE REPLICATION ON/OFF

    Turns replication services on or off

    UPDATE

    Changes the column values of an existing row in a table

    Note: Specifying any DML statements (insert/delete/update) before specifying the BEGIN MLOAD command will use the non-fast path and processing will be done in the Transient Journal (very slow and may exceed the maximum perm space). Specifying the DML statement after the BEGIN MLOAD command will use the fast path and processing will be done in the transaction phase (very fast).

    For syntax and a complete description of each Teradata SQL statement, see SQL Data Definition Language and SQL Data Manipulation Language.