AbortCollect Stored Procedure | Application Programming Reference | Teradata Vantage - AbortCollect - Teradata Vantage - Analytics Database

Application Programming Reference

Deployment
VantageCloud
VantageCore
Edition
VMware
Enterprise
IntelliFlex
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
ft:locale
en-US
ft:lastEdition
2025-11-21
dita:mapPath
qld1628112131956.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
ajo1472244909562
lifecycle
latest
Product Category
Teradata Vantageā„¢

Aborts one or more pending or in-progress collection statements within a running instance of RunCollect.

Syntax

REPLACE PROCEDURE TDSTATS.AbortCollect (
  IN CmdListID BIGINT,
  IN CmdListName VARCHAR(128) CHARACTER SET UNICODE,
  IN DatabaseName VARCHAR(128) CHARACTER SET UNICODE,
  IN TableName VARCHAR(128) CHARACTER SET UNICODE,
  IN RequestID BIGINT,
  IN AbortInProgress CHAR(1) CHARACTER SET LATIN,
  OUT NumPendingAborted INTEGER,
  OUT NumInProgressAborted INTEGER
)
  ...
;

Syntax Elements

CmdListID
System-assigned commands list ID from a prior call to PrepCollect.
For more information about this input parameter, see the usage notes.
CmdListName
Commands list name executed by an in-progress RunCollect.
For more information about this input parameter, see the usage notes.
DatabaseName
Name of the database. DatabaseName identifies the database whose collections within the commands list you specify should be aborted.
TableName
Name of the table. TableName identifies the table whose collections within the commands list you specify should be aborted.
RequestID
Individual collection ID. RequestId identifies the individual collection ID within the commands list you specify that should be aborted.
AbortInProgress
Possible values:
  • Y. If you specify Y, AbortCollect aborts the qualifying collections even if they are already in progress.
  • N. If you specify N, AbortCollect allows in-progress collections to finish. This is the default value.
NumPendingAborted
Number of pending collection statements that were aborted.
NumInProgressAborted
Number of in-progress collection statements that were aborted.

Usage Notes

Identifying a Command List

You can specify both CmdListID and CmdListName as long as they identify the same commands list.
To identify ... You must ...
the commands list being executed specify a value that is not null for either CmdListID or CmdListName.
a commands list by CmdListName assign it during a prior call to PrepCollect.

Aborting Collection Statements

You must specify a DatabaseName, TableName or RequestID input parameter or all collections in the specified command list will be aborted. Those collection statements that do not qualify based on the input parameters you specified are unaffected and will be executed by RunCollect. For more information, see RunCollect.

To abort ... You must specify a value for ...
all collection statements for a particular database DatabaseName.
all collection statements for a particular table both DatabaseName and TableName.
a single collection RequestID.
When specifying a RequestID, it is not necessary to specify DatabaseName or TableName since it is unique across all databases.

Example: Using AbortCollect

The following example shows how to abort all collections within commands list 1 that operate on the Personnel database.

CALL TDSTATS.AbortCollect (1,'MyCmdsList', 'PERSONNEL', NULL, NULL, 'Y', NumPendingAborted,NumInProgressAborted);

Result:

*** Total elapsed time was 1 second.
   NumPendingAborted   NumInProgressAborted    
  ------------------   --------------------
                   2                      1