Example: Non-Support for Iterated Requests With TOP n - Analytics Database - Teradata Vantage

SQL Data Manipulation Language

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2024-04-05
dita:mapPath
pon1628111750298.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
esx1472246586715
lifecycle
latest
Product Category
Teradata Vantage™

The following request indicates the lack of support for specifying a TOP n value as a parameterized variable in a USING request modifier for iterated arrays.

     .REPEAT 1 PACK 5
     BTEQ -- Enter your DBC/SQL request or BTEQ command:

     USING (a INTEGER, b INTEGER, c INTEGER)
     SELECT TOP :a *
     FROM t1;

Result:

     *** Starting Row 0 at Tue Aug 05 11:46:07 2008
     *** Failure 6906Iterated request:Disallowed statement type (TOP N).
   Statement# 1, Info =0
     *** Total elapsed time was 1 second.