Verifies whether a database partition server is being used
by a database. A message is returned, indicating whether the database
partition server can be dropped.
Scope
This API only affects the database
partition server on which it is issued.
Authorization
One of the following authorities:
API and data structure syntax
SQL_API_RC SQL_API_FN
sqledrpn (
unsigned short Action,
void * pReserved,
struct sqlca * pSqlca);
SQL_API_RC SQL_API_FN
sqlgdrpn (
unsigned short Reserved1,
struct sqlca * pSqlca,
void * pReserved2,
unsigned short Action);
sqledrpn API parameters
- Action
- The action requested. The valid value is: SQL_DROPNODE_VERIFY
- pReserved
- Reserved. Should be NULL.
- pSqlca
- Output. A pointer to the sqlca structure.
sqlgdrpn API-specific parameters
- Reserved1
- Reserved for the length of pReserved2.
- pReserved2
- A spare pointer that is set to NULL or points
to 0. Reserved for future use.
Usage notes
If a message is returned, indicating
that the database partition server is not in use, use the db2stop command with DROP NODENUM to
remove the entry for the database partition server from the db2nodes.cfg file, which removes the database partition
server from the partitioned database environment.
If a message
is returned, indicating that the database partition server is in use,
the following actions should be taken:
- The database partition server to be dropped will have a database
partition on it for each database in the instance. If any of these
database partitions contain data, redistribute the database partition
groups that use these database partitions. Redistribute the database
partition groups to move the data to database partitions that exist
at database partition servers that are not being dropped.
- After the database partition groups are redistributed, drop the
database partition from every database partition group that uses it.
To remove a database partition from a database partition group, you
can use either the drop node option of the sqludrdt API or the ALTER DATABASE PARTITION GROUP statement.
- Drop any event monitors that are defined on the database partition
server.
- Rerun sqledrpn to ensure that the database
partition at the database partition server is no longer in use.
REXX API syntax
This API can be called
from REXX through the SQLDB2 interface.