DB2 Server for VSE & VM: Interactive SQL Guide and Reference

CHANGE



>>-CHAnge--/--replaced_string--/----+-----------------------+--><
                                    '-replacing_string--/---'
 

CHANGE is an ISQL command that modifies the current SQL statement in the SQL command buffer and displays the results. If data in the SELECT or FROM clauses of a SELECT statement is changed, associated formatting information for that statement is erased. However, if the changed information is contained in the WHERE, GROUP BY, ORDER BY, or HAVING clauses, associated formatting information for the statement is saved.

/
is any non-blank character that identifies the beginning and end of a string. The slash is a good choice unless you are changing data that contains a slash. This character must be separated from the command name by at least one blank and must not occur in either string.

replaced_string
is the characters to be replaced in the current SQL statement. The string can contain DBCS characters.

replacing_string
is the characters to replace the first occurrence of the characters in replaced_string. If replacing_string is omitted, the first occurrence of replaced_string is deleted. The string can contain DBCS characters.

Example

If the current SQL statement is:

   select * from activity

and you type the following ISQL CHANGE command:

   change /*/actno/

the result in the SQL command buffer is:

   select actno from activity


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]