>>-DROP OPTICAL CLUSTER--+-------+--cluster_name--------------->< '-owner-'
Element | Purpose | Restrictions | Syntax |
---|---|---|---|
cluster_name | The name of the optical cluster | The cluster name must already exist. | Identifier segment; see IBM Informix: Guide to SQL Syntax |
owner | The user name of the owner of the cluster | The specified name must be a valid user name. | Identifier segment; see IBM Informix: Guide to SQL Syntax |
The DROP OPTICAL CLUSTER statement terminates clustering on the optical platter for the TEXT or BYTE data columns associated with cluster name and drops the internal optical cluster table. After the DROP OPTICAL CLUSTER statement is executed, the data items that are associated with the cluster name are stored on the current volume; they are stored in the sequence that they are output to the optical-storage subsystem.
You must be the owner of the optical cluster or have the DBA privilege on the database to drop the optical cluster.
To change the cluster-key columns of an optical cluster, drop the old optical cluster and create a new optical cluster with the new cluster-key columns. You can change your optical clustering strategy so that the cat_picture and cat_descr columns of the catalog table are clustered according to stock_num instead of manu_code, as follows:
DROP OPTICAL CLUSTER cat_clstr CREATE OPTICAL CLUSTER cat_stock_clstr FOR catalog (cat_picture, cat_descr) ON (stock_num) CLUSTERSIZE 6000
After the new optical cluster, cat_stock_clstr, is created on stock_num, all data that is inserted into the database for the cat_picture and cat_descr columns is optically clustered according to the associated value of stock_num. However, the new cluster does not alter the clustering of TEXT and BYTE data already stored on the WORM optical platters. A new cluster affects only subsequent outmigrations. Therefore, in this example, the TEXT and BYTE data that cat_clstr previously clustered retains its original locations. In subsequent outmigrations, the data for the cat_descr and cat_picture columns is clustered by cat_stock_clstr, based on the value of stock_num. Changing the cluster key impacts how the data is stored on the optical platter but not the integrity of the data.
Changing the clustering arrangement often can have an adverse affect on how efficiently data is retrieved. The TEXT and BYTE data that remains clustered by manu_code is effectively unclustered when stock_num accesses it. Accessing it by stock_num can result in frequent platter exchanges. To alleviate this problem, update the TEXT and BYTE data that manu_code previously stored so that it is rewritten in the new stock_num clusters. Because the optical media is WORM, however, the space where the TEXT and BYTE data was stored originally cannot be reused.
Administrators and programmers should be aware that the optical clustering strategy significantly affects the use of space on the optical platters.
Related statements: CREATE OPTICAL CLUSTER