OUTPUT - Advanced SQL Engine - Teradata Database

Database Utilities

Product
Advanced SQL Engine
Teradata Database
Release Number
17.00
Published
June 2020
Language
English (United States)
Last Update
2020-06-15
dita:mapPath
boh1556732696163.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1102
lifecycle
previous
Product Category
Teradata Vantageā„¢

Purpose

The OUTPUT command redirects Ferret output to a file you specify or to the default file STDOUT.

Syntax

{ OUTPUT | OUT }
  [ { TO | OVER | INTO } { file | STDOUT | ME } ]
TO
That Ferret is to redirect output to a new file or to STDOUT.
If the file exists, Ferret returns an error.
INTO
That Ferret is to append output to an existing file specified by file or to STDOUT.
If the file exists, Ferret appends the output to the end of the file.
If the file does not exist, Ferret creates the file.
OVER
That Ferret is to overwrite an existing file or STDOUT with new Ferret output.
If the file exists, Ferret writes over the file.
If the file does not exist, Ferret creates the file.
file
Name of the file you specify as the destination of Ferret output.
STDOUT
Default file to which Ferret writes output.
ME
Synonym for STDOUT.

Usage Notes

When you start Ferret, diagnostic messages are written to STDOUT by default. You can use the OUTPUT command to redirect Ferret output in any of the following ways:

  • To write to a new file only
  • To append an existing file
  • To overwrite an existing file
  • To display on your console
The output file is located on the node that runs the control AMP. To determine which node is running the control AMP, use the STATUS command of the Vproc Manager utility. The control AMP is designated under the Logical Configuration with an asterisk.

When Ferret redirects output to a file, all input and diagnostic messages are echoed to the output file as well as to their usual destinations.

If you include the file parameter in the OUTPUT command, Ferret uses that parameter as the destination for output redirected from STDOUT.

If you type the OUTPUT command without any options, Ferret displays the name of the current output file STDOUT to your system console.

Example: Redirecting Ferret output to a file

The following command example shows the redirecting of Ferret output into a specific file:

Ferret ==>
Output into /home/user1/output.file