IBM Books

Command Reference

CHANGE DATABASE COMMENT

Changes a database comment in the system database directory or the local database directory. New comment text can be substituted for text currently associated with a comment.

Scope

This command only affects the node on which it is executed.

Authorization

One of the following:

Required Connection

None

Command Syntax

>>-CHANGE----+-DATABASE-+--database-alias--COMMENT-------------->
             '-DB-------'
 
>-----+----------------+---WITH--"comment-string"--------------><
      '-ON--+-path--+--'
            '-drive-'
 

Command Parameters

DATABASE database-alias
Specifies the alias of the database whose comment is to be changed. To change the comment in the system database directory, specify the alias for the database. To change the comment in the local database directory, specify the path where the database resides (with the path parameter), and enter the name (not the alias) of the database.

ON path/drive
On UNIX based systems, specifies the path on which the database resides, and changes the comment in the local database directory. If a path is not specified, the database comment for the entry in the system database directory is changed. On OS/2 or the Windows operating system, specifies the letter of the drive on which the database resides.

WITH "comment-string"
Describes the entry in the system database directory or the local database directory. Any comment that helps to describe the cataloged database can be entered. The maximum length of a comment string is 30 characters. A carriage return or a line feed character is not permitted. The comment text must be enclosed by double quotation marks.

Examples

The following example changes the text in the system database directory comment for the SAMPLE database from "Test 2 - Holding" to "Test 2 - Add employee inf rows":

   db2 change database sample comment
      with "Test 2 - Add employee inf rows"

Usage Notes

New comment text replaces existing text. To append information, enter the old comment text, followed by the new text.

Only the comment for an entry associated with the database alias is modified. Other entries with the same database name, but with different aliases, are not affected.

If the path is specified, the database alias must be cataloged in the local database directory. If the path is not specified, the database alias must be cataloged in the system database directory.

See Also

CREATE DATABASE.


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

[ DB2 List of Books | Search the DB2 Books ]