ODBC Server Reference Manual

Transact-SQL Language
HP NonStop ODBC Server Reference Manual429151-002
4-96
UPDATE
UPDATE
Use UPDATE to change data in existing rows, either by adding new data or by
modifying existing data.
The UPDATE statement has the following syntax:
table-reference
identifies the table or view to be updated. The table-name or view-name can be
qualified with the database name and owner name.
column-name
specifies a column to be updated. The first column-name can be qualified with the
database name, owner name, and table or view name.
expression
is a valid expression. Expressions are described under Language Elements
on
page 4-5.
NULL
sets the value to NULL.
FROM
table-reference
is not supported. In the NonStop ODBC Server, this clause generates an error
message.
WHERE search-condition
specifies criteria for selecting the rows to be updated. The search-condition
cannot have a subquery that references the table or view in which the rows are
being updated.
UPDATE table-reference
SET [ table-reference.]column-name = { expression }
{ NULL }
[ column-name = { expression } ] ...
[ { NULL } ]
[ FROM table-reference [ , table-reference ] ... ]
[ WHERE search-condition ]
table-reference is:
[ [database.]owner.] { table-name }
{ view-name }