Maximum Error Level | Basic Teradata Query - Maximum Error Level - Basic Teradata Query

Basic Teradata® Query Reference

Product
Basic Teradata Query
Release Number
17.10
Published
February 2022
Language
English (United States)
Last Update
2022-02-03
dita:mapPath
nnw1608578382132.ditamap
dita:ditavalPath
obe1474387269547.ditaval
dita:id
B035-2414
lifecycle
previous
Product Category
Teradata Tools and Utilities

Other than the return code submitted to the client operating system, BTEQ error severity levels have no immediate impact on operations. Unless they are incorporated into the scripts or macros, each task or job continues regardless of the assigned level of error severity. The MAXERROR attribute, however, defines a threshold value that, when encountered, automatically terminates BTEQ job processing.

If a BTEQ script contains an SQL statement that produces an error severity level that is greater than the designated MAXERROR value, BTEQ immediately aborts that job.

Use the following MAXERROR command, for example, to terminate BTEQ whenever a database error that is assigned an error level of 08 or higher occurs:

.SET MAXERROR 8
If a MAXERROR value is not specified, BTEQ jobs execute until one of the following conditions occurs:
  • End-of-file for the primary command input file is encountered.
  • A QUIT command is processed.
  • A fatal error is detected.
    • When BTEQ receives an I/O abend, system error messages appear in the z/OS JES job log.
    • When BTEQ receives an I/O error or an abend, the IBM/C runtime library produces an LSCX message that might provide more information about the error.

For more information on I/O errors and abends, see I/O Errors and Abends.