Show TOC Start of Content Area

Syntax documentation UPDATE Statement  Locate the document in its SAP Library structure

The UPDATE statement allows updating the values of selected columns of rows of a database table.

Syntax

Syntax

<update statement> ::= UPDATE <table name> SET <assignment list> ( <where clause> )?.

<assignment list> ::= <assignment> ( ',' <assignment> ).

<assignment> ::= <column name> '=' <update source>.

< update source > ::= <value expression>
                                | <dynamic parameter specification>
                                |
NULL.

Caution

You cannot specify string literals as values for CLOB columns. Hex literals, date literals, time literals and timestamp literals are not supported in Open SQL.

Example

Example

UPDATE employees SET employee_name = 'Mary Jones'
                                 WHERE employee_id = 23

Updating Columns of a Table.  The name of the employee with the employee_id 23  is updated to the new value 'Mary Jones' in the database table employees.

More Information

Value expressions

Table Reference

Query Specification

Dynamic Parameter Specification

WHERE Clause

End of Content Area