FROM Clause - Teradata Database

SQL Data Manipulation Language

Product
Teradata Database
Release Number
15.10
Language
English (United States)
Last Update
2018-10-06
dita:id
B035-1146
lifecycle
previous
Product Category
Teradata® Database

FROM Clause

 

Syntax Element …

Specifies …

FROM table_name

the name of a derived table, joined table, or view in the subquery referenced by the predicate of the WHERE clause.

If a row from delete_table is joined with a row from another table in the FROM clause, and the specified WHERE condition for the request evaluates to TRUE for that joined row, then the row in delete_table is deleted; else it is not.

See “Rules for Using Scalar Subqueries in a DELETE Statement” on page 328 for the rules for using a scalar subquery for a derived table.

If you do not specify a FROM clause, then you cannot use correlation names (compare “Example 10: Join Condition DELETE With FROM Clause and Correlation Name” on page 336 and “Example 11: Join Condition DELETE With No FROM Clause” on page 336).

You should also specify the names of all outer tables, including the table from which rows are to be deleted.

AS correlation_name

an optional table alias name.

You must specify a correlation name for each table specified in a self-join.

ANSI calls table aliases correlation names. They are also referred to as range variables.