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...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

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

UPDATE Statement and Atomic Upsert<br />

UPDATE Statement and Atomic Upsert<br />

Purpose<br />

<strong>Teradata</strong> T<strong>Pump</strong> supports the UPDATE <strong>Teradata</strong> SQL statement, which changes field values in<br />

existing rows of a table.<br />

Syntax<br />

where<br />

,<br />

UPDATE tname SET cname = expr WHERE conditional ;<br />

UPD<br />

3021A036<br />

Syntax Element<br />

tname<br />

cname<br />

expr<br />

WHERE condition<br />

Description<br />

Table or view to be updated<br />

This table was previously identified as tname in the BEGIN LOAD command.<br />

If tname is not explicitly qualified by database name, the current default<br />

database qualifies it.<br />

Column whose value is to be replaced by the value of expr<br />

The column named must not be a column of the primary index.<br />

Expression whose resulting value is to replace the current value of the<br />

identified column<br />

The expression can contain any combination of constants, current values of<br />

columns of the referenced row, or values from fields of input data records.<br />

References to fields of input data records are as follows:<br />

:fieldname<br />

where :fieldname is defined by a FIELD command or TABLE command of the<br />

layout referenced by an IMPORT using this UPDATE.<br />

Conditional clause specifying the row or rows to be updated<br />

The conditional clause can use values from fields of input data records by<br />

referring to their field names as follows:<br />

:fieldname<br />

where fieldname is defined by a FIELD command or TABLE command.<br />

Equality values for all the columns of the primary index must be explicitly<br />

specified in this clause.<br />

188 <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!