25.09.2015 Views

Teradata Parallel Data Pump

Teradata Parallel Data Pump Reference - Teradata Developer ...

Teradata Parallel Data Pump Reference - Teradata Developer ...

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 3: <strong>Teradata</strong> T<strong>Pump</strong> Commands<br />

IF, ELSE, and ENDIF<br />

IF, ELSE, and ENDIF<br />

Purpose<br />

<strong>Teradata</strong> T<strong>Pump</strong> provides a structure of IF, ELSE, and ENDIF commands for the conditional<br />

control of execution processes. Conditional execution works as follows:<br />

Syntax<br />

.IF<br />

conditional expression<br />

statements to execute if TRUE<br />

THEN<br />

;<br />

.ELSE<br />

;<br />

.ENDIF ;<br />

statements to resume with<br />

statements to execute if FALSE<br />

3021A024<br />

where<br />

Syntax Element<br />

conditional<br />

expression<br />

statements to execute<br />

if TRUE<br />

statements to execute<br />

if FALSE<br />

statements to resume<br />

with<br />

Description<br />

User-defined variables or pre-defined system variables following the IF<br />

command, whose condition (TRUE or FALSE) triggers the execution of<br />

alternative groups of statements<br />

Statements to be executed whenever the conditional expression following<br />

the IF command evaluates as TRUE<br />

Statements following the optional ELSE command which execute only<br />

when the conditional expression following the IF command evaluates as<br />

FALSE<br />

Statements following the ENDIF command to terminate the conditional<br />

statement execution process and resume the normal command sequence<br />

Usage Notes<br />

The conditional expression in the IF command may consist of either user-defined variables or<br />

predefined system variables.<br />

The ELSE command clause is optional. ELSE is used only when there are statements to be<br />

executed when the condition is evaluated as false. Conditional expression is an expression<br />

144 <strong>Teradata</strong> <strong>Parallel</strong> <strong>Data</strong> <strong>Pump</strong> Reference

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!