Dropping a server definition
Dropping a server definition deletes the definition from the global catalog. The data source object that the server definition references is not affected. You can drop a server definition by using the DROP statement from the command line processor.
Before you begin
You must have SYSADM or DBADM authority to drop a server definition.
About this task
When you no longer need to access a data source server,
drop the server definition from the federated database. When you drop
a server definition, other objects that you registered with the federated
server are impacted:
- All user-defined function mappings, user-defined data type mappings, and user mappings that are dependent on the dropped server definition are also dropped.
- All nicknames that are dependent on the dropped server definition
are also dropped. Dropping the nicknames dependent on the server definition,
affects the objects dependent on those nicknames:
- Any index specifications dependent on the dropped nicknames are also dropped.
- Any views dependent on the dropped nicknames are marked inoperative.
- Any materialized query tables dependent on the dropped nicknames are also dropped.
- All packages and cached dynamic SQL statements dependent on the dropped nicknames are marked invalid, and remain invalid until the dependent objects are re-created.
Restrictions
The
federated server cannot process a DROP SERVER statement within a given
unit of work (UOW) under either of the following conditions:
- The statement references a single data source, and the UOW already
includes one of the following statements:
- A SELECT statement that references a nickname for a table or view within the data source
- An open cursor on a nickname for a table or view within the data source
- An insert, delete or update issued against a nickname for a table or view within the data source
- The statement references a category of data sources (for example,
all data sources of a specific type and version), and the UOW includes
one of the following statements:
- A SELECT statement that references a nickname for a table or view within one of the data sources
- An open cursor on a nickname for a table or view within one of the data sources
- An insert, delete or update issued against a nickname for a table or view within one of the data sources
Procedure
To delete a server definition, issue the DROP statement:
To delete a server definition, issue the DROP statement:
DROP SERVER server_namewhere server_name identifies
the server definition to be dropped.Example: An Informix® server
uses the server name INFMX01. The following DROP statement drops the
server definition:
DROP SERVER INFMX01