DB2 10.5 for Linux, UNIX, and Windows

UPDATE ALTERNATE SERVER FOR DATABASE command

Updates the alternate server for a database alias in the system database directory.

Scope

This command only affects the database partition on which it is executed.

Authorization

One of the following authorities:

Required connection

None

Command syntax

Read syntax diagramSkip visual syntax diagram
>>-UPDATE ALTERNATE SERVER FOR--+-DATABASE-+--database-alias---->
                                '-DB-------'                   

>--USING--HOSTNAME--hostname--PORT--port-number----------------><

Command parameters

DATABASE database-alias
Specifies the alias of the database where the alternate server is to be updated.
HOSTNAME hostname
Specifies a fully qualified host name or the IP address of the node where the alternate server for the database resides.
PORT port-number
Specifies the port number of the alternate server of the database manager instance.

Examples

The following example updates the alternate server for the SAMPLE database using host name montero and port 20396:
   db2 update alternate server for database sample using hostname montero port 20396
The following two examples reset the alternate server for the SAMPLE database:
   db2 update alternate server for database sample using hostname NULL port NULL
or
   db2 update alternate server for database sample using hostname "" port NULL

Usage notes