17.05 - Example: USING Request Modifier with TOP Operator - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - SQL Data Manipulation Language

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
Release Date
January 2021
Content Type
Programming Reference
Publication ID
B035-1146-175K
Language
English (United States)

This example passes the value for n in the TOP n operator in its SELECT request using the INTEGER parameter a as defined in the USING request modifier.

     .SET RECORDMODE ON
     .IMPORT DATA FILE=employee.dat

     USING (a INTEGER)
     SELECT TOP :a *
     FROM employee;