Examples: Using CPU Usage Macros | Resource Usage Macros/Tables | Vantage - 17.00 - Example: Using the ResCPUByAMP Macro - Teradata Database

Teradata Vantageā„¢ - Resource Usage Macros and Tables

prodname
Advanced SQL Engine
Teradata Database
vrm_release
17.00
created_date
June 2020
category
Administration
User Guide
featnum
B035-1099-170K

The following statement executes the ResCPUByAMP macro, producing a report for the period beginning 8:00 a.m. on December 25, 2006 and ending 12:00 midnight, on December 31, 2006. It includes data for nodes 123-02 through 125-04.

EXECUTE ResCPUByAmp('2006-12-25','2006-12-31', 
080000, 240000, '123-02','125-04');

where:

Statement Element Description
ResCPUByAMP Name of the resource usage macro
'2006-12-25' Starting date of December 25, 2006
'2006-12-31' Ending date of December 31, 2006
080000 Starting time of 8:00 a.m.
240000 Ending time of 12:00 midnight
'123-02' Starting node of a range of nodes
'125-04' Ending node of a range of nodes

For information on using numeric values for dates, see Teradata Vantageā„¢ - Data Types and Literals, B035-1143.