cursor_specification - Advanced SQL Engine - Teradata Database

SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.00
Published
September 2020
Language
English (United States)
Last Update
2021-01-23
dita:mapPath
wgr1555383704548.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1144
lifecycle
previous
Product Category
Teradata Vantage™

The SELECT statement specifying the column names or expressions from which to fetch data rows in the CURSOR clause.

You can specify these options for cursor specification statements.

SELECT
The columns or expressions specified by column_name form the cursor.
See Teradata Vantage™ - SQL Stored Procedures and Embedded SQL , B035-1148 for details.
column_name
Name of the column set from which to fetch data.
AS
Optional introduction to column_name_alias.
alias_name
Alias for the table referenced by table_name.column_name_alias is also used to name expressions.
expression
Any valid SQL expression.
table_name
Name of a table or view from which rows are to be fetched.
search_condition
Optional search condition that must be satisfied by the row set to be fetched by the SELECT statement.
Other SELECT Clauses
Clauses such as ORDER BY, GROUP BY, and HAVING.
These clauses are valid only for read-only cursors. None is valid when specified with updatable cursors.
WITH … BY clauses are not allowed in SQL procedure cursors.