sqlupdrow() — Update Row at Open Cursor
Updates the row at the current position of an open cursor. This function supports the EXEC SQL UPDATE...WHERE CURRENT OF... (positioned UPDATE) statement. If you precompile the statement, the preprocessor generates the r-code file to run it.
This function returns normalized values. For more information, see the function return values in the "General Diagnostics" section in this chapter:
sqln
A pointer to the request handle for the open cursor. For more information on request handles, see the "SQL Request Handles" section.
flag
An execution flag that ESQL initializes.
prequest
A pointer to the text of the statement. If you precompile the statement, the text contains the name of the r-code file associated with the statement.
pvformat
A pointer to a format string that describes the types and lengths of the embedded host variables.
psqlv
A pointer to the host variables to which the current SQL request refers.
EXAMPLEThis example updates the row at the position of cursor
x
(associated with request handlesql
0), adding 100 to the value of columnmax-credit:
SEE ALSO
sqldelrow() — Delete Row at Open Cursor for executing positioned DELETE statements, sqldynrq() — Execute a Dynamic Non-SELECT Statement for updating rows of dynamic cursors, sqlrequest() — Execute a Static ESQL Statement for executing non-positioned static ESQL statements.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |